Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Javascript > Quick Question

Reply
Thread Tools

Quick Question

 
 
BryanA
Guest
Posts: n/a
 
      11-02-2008
I am new to JS and after googling for a little while I couldn't find
an answer to my question. I have an ajax JS that auto updates a
certain element. The problem is it has to request another page for
each individual page that it sits on. I have a php get in there but
because this site is in full js, every time I pass a variable through
the url it starts back at the base page. The javascript sits at the
top of the page and then loads in other pages and acts as a template.
How should I go passing the current page url into the JS? I was
thinking about using a variable in the element that it refreshes but
am unsure of how to do that.

Any suggestions?

Thanks,
Bryan A
 
Reply With Quote
 
 
 
 
BryanA
Guest
Posts: n/a
 
      11-03-2008
On Nov 2, 8:29*am, BryanA <(E-Mail Removed)> wrote:
> I am new to JS and after googling for a little while I couldn't find
> an answer to my question. I have an ajax JS that auto updates a
> certain element. The problem is it has to request another page for
> each individual page that it sits on. I have a php get in there but
> because this site is in full js, every time I pass a variable through
> the url it starts back at the base page. The javascript sits at the
> top of the page and then loads in other pages and acts as a template.
> How should I go passing the current page url into the JS? I was
> thinking about using a variable in the element that it refreshes but
> am unsure of how to do that.
>
> Any suggestions?
>
> Thanks,
> Bryan A


To further explain, the url format is: http://www.example.com/index.php#page
which turns into http://www.example.com/#page

Because the #page is just the id of the page and the js file is
sitting at the top of the page it can't be edited with url parameters
which is what I need?

Any Help is much appreciated!

-Bryan
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Quick question, hopefully quick answer. ~misfit~ NZ Computing 114 01-06-2005 01:36 PM
Quick Question Quick Answer JKop C++ 11 05-24-2004 09:46 PM
Quick Restore for a Compaq not so quick! Croos Bustamunky Computer Support 2 05-15-2004 04:17 AM
PanasonicBQ390 "quick" charger - How quick? Ol' Bab Digital Photography 1 01-17-2004 06:54 AM



Advertisments