开发者

javascript capture and display php variable

开发者 https://www.devze.com 2023-03-31 18:32 出处:网络
I have standard text links which all say \"Full View\". When clicked these links send out php in this form: http://mysite.com/fullview.php?myimage=30

I have standard text links which all say "Full View". When clicked these links send out php in this form: http://mysite.com/fullview.php?myimage=30

Basically there's thumbnailed images and text links that say full view. I'd like for fullview.php to capture the myimage variable, and display it as a full sized ima开发者_运维问答ge. Meaning, a blank page (fullview.php) displaying the image. Sounds likes javascript to me.

How do you put the javascript into fullview.php to capture the variable and display it as a full sized image?

Thanks for any help, Darrell


php is server side script javascript is client side script

so displaying a web page to a user first is executed php and result is send to client. After he receive it then javascript is executed

HTH

Ivo Stoykov


You just need to read the query parameters. In fullview.php you can use

$myimage = $_GET['myimage']; to capture this variable. And then can use it accordingly.

0

精彩评论

暂无评论...
验证码 换一张
取 消