Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

The Database Forum


You are currently viewing our The Database Forum as a guest. Please register to participate.
Login



Reply
java scriptfunction from mysql
Old 08-14-2006, 05:36 PM java scriptfunction from mysql
atomicshockwave's Avatar
Experienced Talker

Posts: 38
Trades: 0
hi i am looking for a way to do this:

i have a function createDefaultBoxes() this function is used to call a list of functons, what i want to do is have the function createDefaultBoxes() to call its function from a mysql database.

any help would be great!
atomicshockwave is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 08-15-2006, 03:19 AM Re: java scriptfunction from mysql
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,519
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
Quote:
to call its function from a mysql database
Explain this please

BTW javascript can only run on a javascript enabled user agent (browser), so I rather suspect the answer is;
You can't.

However more detail on exactly what you mean may change that.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 08-15-2006, 08:23 AM Re: java scriptfunction from mysql
atomicshockwave's Avatar
Experienced Talker

Posts: 38
Trades: 0
ok i have a user managment script on my site, and also on my site i have java script. now one of my javascript functions on my site is createDefaultBoxes()

now what i want to do is have users on my site be able to have controle over what this function dose and stor it in there user pref in my sql database.
so based apon the database the function when it is called would refer to the database for what to execute
atomicshockwave is offline
Reply With Quote
View Public Profile
 
Old 08-15-2006, 06:15 PM Re: java scriptfunction from mysql
chrishirst's Avatar
Missing! presumed drunk.

Posts: 41,519
Name: Chris Hirst
Location: Blackpool. UK
Trades: 0
javascript cannot "talk" to the database, so the only thing that can be done it that whatever server side code you use could write variables and values into the page code for the javascript to read.
__________________
Chris. ->> Links are advertising NOT optimising!! <<-
A foolish consistency is the hobgoblin of little minds
Thought for today:- I SEO the only industry where all the cowboys are Indians?
chrishirst is online now
Reply With Quote
View Public Profile Visit chrishirst's homepage!
 
Old 08-23-2006, 09:22 PM Re: java scriptfunction from mysql
atomicshockwave's Avatar
Experienced Talker

Posts: 38
Trades: 0
ok, well i know that, but is there a way to do kinda like a php include to give the value of the java script function?
atomicshockwave is offline
Reply With Quote
View Public Profile
 
Old 08-23-2006, 10:00 PM Re: java scriptfunction from mysql
mgraphic's Avatar
Truth Seeker

Latest Blog Post:
JAMISONTUNES
Posts: 2,898
Name: Keith Marshall
Location: Connecticut
Trades: 0
It sounds like you may have a chance with this using AJAX. Using AJAX can make requests to the server that prompts a php script to do the db work, and this would happen within the html page the user has in thier browser.
__________________

<mgraphic /> - I don't have a solution but I admire the problem.
mgraphic is offline
Reply With Quote
View Public Profile
 
Old 08-24-2006, 07:10 PM Re: java scriptfunction from mysql
atomicshockwave's Avatar
Experienced Talker

Posts: 38
Trades: 0
how might i do this?
atomicshockwave is offline
Reply With Quote
View Public Profile
 
Old 08-24-2006, 09:08 PM Re: java scriptfunction from mysql
mgraphic's Avatar
Truth Seeker

Latest Blog Post:
JAMISONTUNES
Posts: 2,898
Name: Keith Marshall
Location: Connecticut
Trades: 0
I have not yet done anything using AJAX, but there are a ton of targeted tutorials in the JavaScript forum:

http://www.webmaster-talk.com/javasc...tutorials.html

And take a look at the AJAX Client-Server Communication Tutorials
__________________

<mgraphic /> - I don't have a solution but I admire the problem.
mgraphic is offline
Reply With Quote
View Public Profile
 
Old 08-25-2006, 11:43 AM Re: java scriptfunction from mysql
saadatshah's Avatar
Extreme Talker

Posts: 215
Name: Syed Saadat Ali
Location: Lahore, Pakistan
Trades: 0
Yeah AJAX is right
__________________
- -- --- ---- ----- ------ ------- ---------------
If you have knowledge, let others light their candles in it.
saadatshah is offline
Reply With Quote
View Public Profile Visit saadatshah's homepage!
 
Reply     « Reply to java scriptfunction from mysql
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.28735 seconds with 12 queries