PHP - Beginners Project In Php
Hi guys,
I'm a beginner in php.I know some basic codings in it.I want to do the project in php.Help me how to start..?..and what kind of project is best for beginners to learn..?
Similar TutorialsI need some helping with writing code for a web page that allows users to enter information in a PHP form along with proceeding to a PayPal payment page after entering the info. The information entered will be added to an SQL database, and only added after payment confirmation, then have those database entries expire after 1 month. This is what I have got so far, not sure if it is even correct. If it is, then I just need to added PayPal payment and SQL database expiration code. <html> <head> <title>Server Donation Page</title> </head> <body> <?php $hostname = "hostname"; $db_user = "dbuser"; $db_password = "dbpassword"; $database = "database"; $db_table = "table"; $db = mysql_connect($hostname, $db_user, $db_password); mysql_select_db($database,$db_table); if (isset($_REQUEST['Submit'])) { $sql = "INSERT INTO $db_table(id,user_email) values ('".mysql_real_escape_string(stripslashes($_REQUEST['id']))."','".mysql_real_escape_string(stripslashes($_REQUEST['user_email']))."')"; if($result = mysql_query($sql ,$db)) { echo '<h1>Thank you,</h1> your information has been entered into our database sucessfully.<br><br><img src=""'; } else { echo "ERROR: ".mysql_error(); } } else { ?> <h1>Server Donation Page</h1><hr> <form method="post" action=""> Steam ID (format STEAM_0:x:xxxxxxxx, go to <a href="http://www.steamidfinder.com">Steam ID Finder</a>):<br> <input type="text" name="id"> <br> Your Email: <br> <input type="text" name="user_email"> <br><br> <input type="hidden" name="authtype" value="steam" /> <input type="hidden" name="flags" value="o" /> <input type="hidden" name="immunity" value="0" /> <input type="hidden" name="identity" value="donator" /> <input type="submit" name="Submit" value="Submit"> </form> <?php } ?> </body> </html> Thanks in advance! Hi, I rarely deal with PHP, so this may sound very easy, but I am struggling to figure out what to do. Basically I have created a website for a client that allows for customers to pay for certain packages using Paypal. They select the package they want, which then takes them to a data input page (email, tel no, name etc). Once they click submit, that information gets emailed to my client, and the customer is presented with the relevant Paypal page. What I need is on each data input page, for a checkbox to be available, so if the customer checks the checkbox, they get taken to a different paypal page rather than if they leave it blank. So really, what I need is if the checkbox is left blank and that page is submitted, the customer goes to Page A. If the checkbox is checked and they click submit, the customer goes to Page B. Any help would be greatly appreciated! Cheers Graeme Hi - I know this is a #101 question but here goes! I simply want to select a single row from a table and use the columns fields as variables that can then be posted in a form. $result = mysql_query("SELECT * from tblquestions WHERE qid='1'"); if (!$result) { echo 'Could not run query: ' . mysql_error(); exit; } $row = mysql_fetch_row($result); $oid=$result['oid']; $qid=$result['qid']; $question=$result['question']; The code above isn't working - as when I try to echo each variable <?php echo $question;?> nothing is being shown on screen. I'm obviously barking up the wrong tree in the way I'm trying to create the variable - but don't really have any idea where to look next. Hello I am new to the forums and this is my first post A little about me, I have played around with php time to time but don't know how to code it, I can modify it and use scripts and what not but I can't find a script that I wan't to do this I wan't to be able to upload and file share site without using mysql and using cookies instead to keep track of user's upload's without having them to register a account, I don't want a user management system for this I just want them to be able to upload a file and it keep track of their upload's(I can set a limit of course), and be able to share the direct link to their friends for them to quickly download it. I need to know what steps I need to do and how to start basically and if anyone can help me out. Thank you PHP Freaks About Me Hi, firstly let me introduce myself. My name is Liam O'Connor and I'm 17 years old, 18 soon (quite excited) living in the UK and I've been learning how to makes websites ever since I was 16. Within the last 2 years I have taught myself (x)HTML/CSS, PHP/MySQL, JavaScript/Ajax to a good standard. I'm currently at college doing a Computing Networking and Security Extended Diploma. The Project I have been working on a website for many months now that I REALLY love doing. When ready for launch the website will be a simple social networking website that lets users communicate in groups or one-on-one, also users will be able to create chats on the topics they like to talk about and personalise them to how they like. What have I done so far? Within the last few months I have created a well working chat system that allows many users to communicate together, and many features within the chat such as emoticons, change status (online, busy, away), control of font size, sound alerts, chat comments, and a thumb rating system. What could you do? If you are interested to help develop a website like this one (for free) in your own time, please contact me and let me know a little about you and what you think you would be able to offer. There is no rush to get this project finished and put live for the world to see so there would be no pressure on you. If you are not interested in developing the website but you believe you have some wise words of wisdom please share them with me or if you believe you can help in any other way please let me know. Please check out the image below Thanks So I am working on a project in which I am taking pictures from an SSH area, running ImageMagick on the picture to crop out what I want and then use the threshold to make it like I want, and then finally run Tesseract OCR on the final picture. I have a new picture coming in to the spot I am taking the pictures from every six seconds and I need the program to run the commands to do all of this every six seconds as the pictures come in forever basically. As of right now, here is my code that I have. I am relatively new to using PHP scripting working for the command line in Ubuntu. So if anyone could help me with some fixes to this code, I would be greatly appreciative. Code: [Select] <?php function tesseract($image) { define($ocmd, `ssh *place i am taking from*`); fwrite("<pre>$ocmd</pre>"); define("$pic1", "`convert $image -crop 1000x170+350+785 -negate -threshold 42000 $image.tif`");//This is a 1920x1080 hd image define("$pic2", "`convert $image -crop 600x95+200+550 -negate -threshold 41000 $image.tif`");//This is a 1280x720 hd image define("$pic3", "`convert $image -crop 650x100+75+550 -negate -threshold 43000 $image.tif`");//This is a 960x720 hd image define("$pic4", "`convert $image -crop 500x62+175+410 -black-threshold 53% $image.tif`");//This is a 960x540 hd image define("$cmd2", "`tesseract $image.tif $image.txt`");//command to take the words of the edited image list($width, $height) = ImageCreateFromJPEG(filename); define("$area", "($width*$height)"); if ($area == 1920*1080) { $line = $pic1; } elseif ($area == 1280*720) { $line = $pic2; } elseif ($area == 960*720) { $line = $pic3; } elseif ($area == 960*540) { $line = $pic4; } else { $line = "Please try a picture of another size."; } echo("<pre>$line</pre>"); if ($line != "Please try a picture of another size.") { echo"<pre>$cmd2</pre>"; } } ?> well done really need help but this seemed the best place to put it well i was wondering what would be easy 1st project for a beginner to make in php, Hi, I need more than one person on my team for my project, I was wondering if someone will join and help me. My project it a website software (kind of like a CMS). This won't be paid. That's the only problem.
hi Guys..............i am final year student and i need to submit a project that should me medium to large size and i want to build it on PHP so it would be very kind if you can kindly suggest me topics for the same however there is just one restriction the process that i cannot build anything like management systems or social networking websites the idea should be new and catchy and ya one more thing no e-com websites as well.....................looking ahead for your advice..................thank you. i am having a problem passing variables from a php file to a html file using a javascript funtion. here is the code i have. Code: [Select] /////////InteractiveMap.HTML//////////////////////////////////////////////////// <script type="text/javascript"> // This function is called when a building is clicked. function buildingClick(id,name,desc) { var mywin; var isOpen = false; var searchInt; var passVal; passVal = desc; mywin = window.location.href = "informationPage.html"; searchInt = setInterval(function(){if(isOpen){var display=mywin.document.getElementById("infoArea"); display.value = passVal;}});} /////////////////////////////////////////////////////////////////// ////////////InformationPage.html/////////////////////////////// <script type="text/javascript"> window.onload = function(){window.opener.window["isOpen"] = true;}; </script> <textarea disabled id="infoArea"></textarea> ////////////////////////////////////////////////////// I am just tryin to display the variable desc in the textarea "infoArea" but it wont work.Any help would be appreciated. eoin Okay, let's say I have a block of text like so; 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 I need to be able to add more/less digits to the text. Like so; 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 0x00000000 etc Also if it's greater than a certain number, to subtract. :3 How would I go about doing that? Thank you, Doctor This topic has been moved to PHP Freelancing. http://www.phpfreaks.com/forums/index.php?topic=319234.0
hello , Im working on a fictional web-site as a final project for my course.
with my limited PHP programming skills I have managed to successfully a produce a css button maker which makes and produces the code for a number of resolutions and devices. this is the $result displayed Code: [Select] $result = "<a href='#' class='blnk'><li class='btn rnd'>" .$_SESSION['text'] ."</li></a>"; ($_SESSION['result']==$result); this is how each device is called: Code: [Select] #### ANDROID ####### if ($_SESSION['device']=="android") { echo "<div id='andt'></div><div id='andm'><div id='and-st'><div id='btn'>"; $i=1; while($i<=$_SESSION['nbr']){ echo $result; $i++; } echo "<div class='cl'></div></div></div></div><div id='andb'></div>";} This is the dropdown for the bumber of buttons Code: [Select] <legend> Button No</legend> <select name="nbr"><option value="<? echo $_SESSION['nbr'] ?>"><? echo $_SESSION['nbr'] ?></option><?php include('inc/f-1to8.php'); ?></select></fieldset></td> Code: [Select] <tr> <td colspan="3"><fieldset><legend>Button Text </legend><input name="text" type="text" value="<? echo $_SESSION['text'] ?>" size="50" maxlength="16" /></fieldset></td> What I need is to know howto not only produce a number of Button Text input boxes that correspond to Button No but ones that each correspond individual buttons so each button has its own text field. If anyone can help it would be much appreciated - Im suprised I have got as far as I have. here is the link at the mo http://www.d-sine.com/_STYLES/buttons.php - (the reset button will set default settings by going to a page that posts back default settings in hidden fields on a meta refresh) Kind Regards Fatal error: Method name must be a string in C:\xampp\htdocs\cmsv2room\model\getTimeTableClass.php on line 216 i am using setters ang getters for arrays while setting an array in a array i get this error the line in which i got the error is below $gettimetableObject->$setFacnameArray($FacnameArrayR); actually iam storing arrays in an array $FacnameArrayR is an array storing in a array with help of object(concept of setters) This topic has been moved to Miscellaneous. http://www.phpfreaks.com/forums/index.php?topic=306541.0 So I have decided to do research as my project and gain something from this. But also I will have to include programming which i prefer PHP. and will be testing these for my research. Does this sound like a good project and also If it is good sound.. Where do I start?... need a starting point and then I could go on to doing it.. Hi all, I am an intermediate PHP Programmer, but I'm now stuck with getting any further. I am currently developing a CMS with a few people. However, I wish to put that aside for a month or so and learn PHP a bit better. Can anyone suggest a fairly "easy" project for me to do to learn a bit more about PHP? Best Regards, DM I'm doing a project using PHP to store reviews by people in the database.
http://postimg.org/image/3l9j1uipf/
When the 'Add Reviews' is clicked, it goes here
> http://postimg.org/image/q07qvnluh/
Here comes the problem, I need to add radio buttons / groups for people to select their phone rating 1-5.
& in the front page (the page with add / search / list), it displays the ranking / rating of phones.
Anyone have any idea how do I do the codes?
Edited by Axton, 06 August 2014 - 05:18 AM. |