Jump to content

lewisstevens1

Members
  • Posts

    88
  • Joined

  • Last visited

Everything posted by lewisstevens1

  1. hi i have a problem, i am not great at php and mysql, i know the theory of it, so i have a 2 php documents attached in a .zip file, its just like pseudocode of what i want to say, i will give you a copy of it here but it may be easier to read if you had the files. I dont know what i can do with it, i know how to create a table read data from mysql database, but im not too sure about this. each pseudocode has a different way id like to do it, though if i could just get one working that would be great, one way may be easier for others, im just trying to give an idea of what i want to create. i will post the code here as well, thankyou if you can help me. the "------" is the break for psudocode, the "____" is for break of files or sections. the pasted code here has no comments unlike the attached files. ___________ upon affiliatepayment {+"usertokens" to "usertokenstotal"} end __________ if "usertokenstotal" >= "usertokenspayment" then {-"usertokenspayment" from "usertokenstotal"} then {increment "userdplevel" by 1} if "userdplevel" > 3 then echo "Sorry you allready have the highest level dp available" else echo "Sorry you do not have enough money to make this purchase" end ___________ if "userdplevel" = 1 then load imgsrc ("www.mysite.com/images/dplevel1.png") else continue if "userdplevel" = 2 then load imgsrc ("www.mysite.com/images/dplevel2.png") else continue if "userdplevel" = 3 then load imgsrc ("www.mysite.com/images/dplevel3.png") else end __________ /*More Comments*/ Well, i want the data to be stored in a database, i want: "usertokenstotal" "userdplevel" though the images will be stored on the server. the usertokens payment i think i will want a set amount, so lets say we'd replace the usertokens payment with 50, either that or i could have a text file to add how much id like to have it updated by. i dont really mind, i would even be ok if another feild was created to store how much it was ment to be updated by. id like to store the dp in the div i have created. Many thanks Lewis Stevens Greatly Appreciated ----------------------------------------------- Thats the first doc. but there is another attached. [attachment deleted by admin]
  2. Cool thankyou guys.. it all works now =D i can start playing around the code to suit my needs a bit more =D thanks
  3. yey that works.. thanks.. but do you know if you can make it look like its in a disabled text box, i used to be able to do, but it may be cus its in a .php file, normally i put it around e.g. <html> <form = wateva disabled> <php? ?> </form> </html>
  4. Fatal error: Call to undefined function eof() in /home/stonersg/public_html/Lee/user.php on line 3 i have: <?php $f=fopen("progress.txt","r"); while (!eof($f)){ $line=fgets($f); echo $line,"<br/>"; } fclose($f); ?> so line 3 is: while (!eof($f)){ which calls f? mmm im just wondering about the progress.txt ive created a file on my server called progress.txt and saved as a blank .txt doc... is that whats needed?
  5. Well i did notice that you missed out the <? > but i added them in after... i though u just misstyped lol...
  6. The error i get from admin.html is: $progress=CLEANED VERSION of $_POST['progress']; $f=fopen("progress.txt","w"); fputs($f,$progress); //$progress is the text you want to display from the admin form fclose($f); So it just displays the code of the page after i have pressed submit, after entering some data. then it just stays there, so i edit the url to /user.php then it just comes up with: $f=fopen("progress.txt","r"); while (!eof($f)){ $line=fgets($f); echo $line," "; } fclose($f);
  7. =S well the code does not work, though unlike HTML and CSS... i dont av a clue what half of it does. i understand while get echo $ $_post and all this <form method="post" action="processAdmin.php"> <textarea rows="5" cols="20" name="progress"></textarea> <input type="submit" /> </form> just not sure about the rest
  8. im sorry i dont understand how that can work? is there anynew code i need to add?
  9. lol well the page will only be one password which i can easily do on my server... nothing to code. but i just want something which overwrites the last post... it should just be like a display window.. where you see whats posted in there, though when you log off it will stay there untill someone changes it.
  10. Hi i think i have to use the php function $_post and $_get functionis... but i am not sure... i have a image showing what i want to do, can someone help me, its verry basic but looking around on all forums i cant find. it needs to be stored on a server for a bit untill then next submition of the data. i want it so they can post a daily update of the progress of the development. heres a link to the image: http://i261.photobucket.com/albums/ii64/lewisstevens1/sever.jpg
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.