|
You need a replace function, not a substring function. Probably string.replace("\", "")
Jeff Martin
My Blog
|
|
|
|
|
Monisankar wrote:
Actually i am doing a program in JSFL(Flash Javascript).So i
posted the thread here and it's a basic problem.
Suppose,
string = 'welcome to moni\'s homepage'
var i = string.indexOf("\'");
var j = string.indexOf("\'",j);
valueOfString = string.substring(i+1, j);
now valueOfString is welcome to moni
but i need to return it as welcome to moni's homepage.
What should i do?Thanks
As said, in the previous reply to your question you either need a replace method, or you need to add on the end of the string to the current one.
Ie. valueOfString = string.substring(i+1,j) + string.substring(j+1,stringLength)
I don't know what the string length function in JSFL though...
_____________________
Don't take out the Magic Pen,
Don't draw on the Infinity Board
- Neil Young
|
|
|
|
|
Thanks to both of u.
Got it and solved.
Thanks
|
|
|
|
|
A few months ago, I found an article on making like a class with java script. It forgot the link. Any body knows this article? Thanks.
<italic>Work hard, Work effectively and a bit of luck is the key to success.
|
|
|
|
|
You mean this? [^](Use Javascript object like you do it in C#] [http://weblogs.asp.net]
Edbert
|
|
|
|
|
Hi guys,
I searched all over the web for a login script in JAVASCRIPT!! but all i could find is VBscripts. Can someone please help, i desperatly need a JS login script that links to an access database.
Thanks!
|
|
|
|
|
in my web page i put 3radio button one buuton for excel.2nd button for html and last one for pdf.so when user click on the button a save as dilog box will open with corresponding file format.for example if a user choose excel button then a save as dilog box will open with save as type *.xls.i also want to retrieve the full physical path where the user store the file.
how i'll do this in java script plz any body know help me.
with regards
swagatika
|
|
|
|
|
Hello there,
Recently I have been developing Java Applet program. And I am trying to use HTML to design the main page. What I am in doubt is I have a ENTER button. When user press on the ENTER button, the developed Java Applet will be loaded.
However, I dont know what code or line of stuff i need to do to make the above scenario happened. For your information I am using Front Page to create the HTML page and JCreator to do the Applet Program.
Please help!
Thanks,
Lee
|
|
|
|
|
Hi,
I have data retrieved from Oracle into a jsp page where onload i like to append the '$' and '%' symbols along with the data onload. Let me know, if anyone know how to do this.
Thanks,
angel
|
|
|
|
|
Never done any Web development before, but would like my MFC dialog program to interface with Web Pages. The server will obtain data and this data will be displayed on Web Pages.
My 1st question is what should I be looking at to use Edit boxes, push buttons combo list etc on the Web Page to Get/Set various options using these controls. Can I do it with plain HTML, or do I need to use ASP or JavaScripts. I have just started to use HTML, so a good tutorial would be very helpful.
2nd question, how do I get hold of the data on these controls (Edit box, combo list- on the Web Page) in my MFC program. I have placed an ActiveX Web Browser on my main dialog. Currently I can Set/Get the Web Browsers current ULR.
grahamfff
|
|
|
|
|
I assume the web pages you will be creating will be on a web server and not on the local machine. I know some developers put their help section in a web page and make it a part of the installation on the end-user's computer, but this limits you to what can be done. If it is on the server, you can use whatever you like.
The good news is you can do it with plain HTML if your help section is pretty basic. This would give you pages with text and regular hyperlinks. If you want to add in something like a text search or anything like that, you will need to use a back-end language like ASP, PHP, etc. I wouldn't worry about javascript for your situation.
If the files are on a web server, you can start out with raw html and later beef-up the pages with ASP or whatever you want. If you are new to web development, stick to the easy path until you want to add in more things.
|
|
|
|
|
Thanks for your post.
I will be using Visual Studio .Net to produce these Web Pages, but having trouble getting a value from an Edit Box or Combo into say a table on the Web Page. Is that another page?
May be getting confused with MFC C++ events etc
Any good sites/books for getting started, writing simple display Web Pages is OK its the interaction/moving data around.
Thanks.
grahamfff
|
|
|
|
|
When I go to http://localhost I get the error "Bad Request". When I try http://127.0.0.1 I get my local site. My Hosts file has an entry for localhost.
I'm running Windows 2003 / IIS6. I'm going insane.
Anyone have any suggestions?
cheers,
Chris Maunder
|
|
|
|
|
Verify that your site is listening to all addresses on the host. Then check to see if the site is reading the header data for hostname resolution. The problem is most likely to be with the second one.
|
|
|
|
|
Hi,
I want to Save images from a website programatically and not by the "Save Image As..." Option. I have certain websites in my list which provide these images and I want to scrape images from there on to the hard disk.
Any suggestions ?
Thanks.
|
|
|
|
|
Howdy all.
Something that should be incredibly simple I would appreciate some help with.
How do you use the Post method to send data to an asp page without building a form, setting field values and requiring the user to click on a button?
In fact, the only thing that needs to be different from the normal idea of using the "POST" method is that the user shouldn't need to click a button, it should be clicked automatically.
Does this make sense? Can anyone help sort me out?
Cheers all,
Kutz
_____________________
Don't take out the Magic Pen,
Don't draw on the Infinity Board
- Neil Young
|
|
|
|
|
Ok... I'm silly. Don't worry.
I believe the answer is to use javascript.
Ie. Document.formName.submit();
Cheers for reading, if, indeed, you're reading this.
Adios,
Kutz
_____________________
Don't take out the Magic Pen,
Don't draw on the Infinity Board
- Neil Young
|
|
|
|
|
If you need to shield youself away from some details and are not interested in how somethings are done I would suggest you get clasp asp framework. Posting data automatically in ASP has never been that simple before the era of .Net
|
|
|
|
|
Cheers for that, but it's not really that I want to shield myself away from these details, but my users from having to make an extra click. I was simply forgetting one of the more simple methods available in the DOM.
Cheers though.
PS. What the heck is clasp?
|
|
|
|
|
CLASP is a Framework developed in VBScript for the development of Classic ASP WEB applications.
It simplifies your coding and makes it very portable to ASP.NET.
Provides you with a rich event driven environment that resembles ASP.NET and Visual Basic Windows applications.
Supports ViewState and other cool features.
It has a large list of web controls
Many of the controls has a method call autopostback that allows your form data to be posted automatically without your user clicking the submit button
|
|
|
|
|
Cheers mate for the info.
_____________________
Don't take out the Magic Pen,
Don't draw on the Infinity Board
- Neil Young
|
|
|
|
|
Hi,
how do I check whether the entered email ID is valid or not?
I found this filter :
var filter=/^([\w-]+(?:\.[\w-]+)*)@((?:[\w-]+\.)*\w[\w-]{0,66})\.([a-z]{2,6}(?:\.[a-z]{2})?)$/i
if (!filter.test(str))
{
alert("Please input a valid email address!")
return false;
}
But I can not interpret the filter.
can anyone help?
|
|
|
|
|
First off....whats a email ID???
filter is a regular expression...read up on those first....then try and interpret it
As far as I can tell from just glancing at the regex...it is indeed checking for a email address...
Just copy and paste and you'll be good to go...
It's frustrating being a genius and living the life of a moron!!!
|
|
|
|
|
Hi,
I have a MS access database of product's table namely
with fields imagefile, product_id, name, cost and 4
different products added.
I created a table 2 rows 2 cols in products.aspx, i have
the database connected, datasets up and i wish to display
the 4 products into this 2 row 2 col table i created, how
is that possible?
Earlier i setup'd a datagrid and managed to list all of
the products in one table but i can't do anything
to it and it is not the table i want.
How do i pull individual product id and its other info
in each of my cols in my table rows..
Thanks,
Josh
|
|
|
|
|
What you can do is to create a repeated region which loops through the dataset adding the appropriate code.
Go to Insert -> Application Objects - > Repeating region.
You can set the number of repeats for this region. Also, you can set a datasource for it. This means that each time the region repeats it will navigate to the next row in your table.
Will look similar to below
Ie ASP:Repeater runat="server" DataSource='<%# MyDsTable.DefaultView %>
Within this region, place the code that you'd like to see repeated.
<br />
Ie. <tr><td> <%# MyDsTable.FieldValue("Field1", Container) %></td><br />
<td> <%# MyDsTable.FieldValue("Field2", Container) %></td><br />
</tr><br />
This will create a new row for your table for each record in the dataset for however many times you repeat that region.
Make sense?
_____________________
Don't take out the Magic Pen,
Don't draw on the Infinity Board
- Neil Young
|
|
|
|