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.

PHP Forum


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



Freelance Jobs

Reply
Old 08-09-2004, 07:05 AM Variable in variable
lajkonik86's Avatar
Ultra Talker

Posts: 389
Trades: 0
i have a variable called $pic
And i've got a bunch of variables called $1 up till $14
now i would like to set $$pic = 4
$pic will always be a number between 1 and 14.

What's the proper code for this?

Greetz
Thierry
lajkonik86 is offline
Reply With Quote
View Public Profile
 
 
Register now for full access!
Old 08-09-2004, 08:26 AM
Unknown.

Posts: 1,693
Trades: 0
Not quite sure what you mean...

What exactly are you trying to do?

-James
Dark-Skys99 is offline
Reply With Quote
View Public Profile
 
Old 08-09-2004, 08:58 AM
webwoRRks's Avatar
Ultra Talker

Posts: 426
Location: I hope so
Trades: 0
do you mean a random number, or incremental, or you want to verify the number is between 1 and 14.... ?
__________________
Theres 10 types of people; those who understand binary, and those who don't.
webmaster and webdeveloper resources,
Please login or register to view this content. Registration is FREE
webwoRRks is offline
Reply With Quote
View Public Profile Visit webwoRRks's homepage!
 
Old 08-09-2004, 09:27 AM
Wenslock's Avatar
Webmaster Talker

Posts: 746
Location: Lincoln, UK
Trades: 0
That is a bit of a head scratcher. If you can, try to split the definition of what you mean up.
__________________
------------------------------------------------------------

Please login or register to view this content. Registration is FREE
- Black Prism professional web design services
------------------------------------------------------------
Wenslock is offline
Reply With Quote
View Public Profile
 
Old 08-10-2004, 08:14 AM
lajkonik86's Avatar
Ultra Talker

Posts: 389
Trades: 0
Sorry guys

What i was trying to do is let variable $pic determine which variable should be set at 4
so i would have $$pic=4
So if $pic would be 5 $5 would be set to 4 and if $pic 7 $7 would be set to 4

I couldn't figure out how to do this so i did it with $border[$pic]=4
And set $border[1]=0 till $border[14]=0 offcourse these where declared before $border[$pic]=4.

Greetz
Thierry
lajkonik86 is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to Variable in variable
 

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.76569 seconds with 12 queries