PHP Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 



Go Back   Dev Articles Community ForumsProgrammingPHP Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
  #1  
Old February 20th, 2004, 08:32 PM
aalowe9 aalowe9 is offline
Registered User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Posts: 5 aalowe9 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
simple php question

I have a page (index.php) and linked to that i have a
include page where i have defined a function called getInfo();
which just drags data out of my database, this works with no problems. I want
it to work so that the getInfo() function is only run when a button is pressed
in the index.php. I want somehting like
<img src="36.gif" width="18" height="18" onClick= <? getInfo() ?>>
only somehting that works instead, how do i sort this? thanks alot,

Reply With Quote
  #2  
Old February 23rd, 2004, 04:32 AM
Spongy's Avatar
Spongy Spongy is offline
Alternately High
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Feb 2004
Location: Hilversum, Netherlands
Posts: 223 Spongy User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 56 m 41 sec
Reputation Power: 14
Send a message via MSN to Spongy
It will never work with the onClick statement. This is used by js and is executed on client-side while your function has to be executed server-side.
Try it with a iframe which is hidden, or with extra GET-variables.
__________________
Work to live, don't live to work

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingPHP Development > simple php question


Developer Shed Advertisers and Affiliates


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump

Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 


Powered by: vBulletin Version 3.0.5
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.

© 2003-2018 by Developer Shed. All rights reserved. DS Cluster - Follow our Sitemap