Jump to content

fantomel

Members
  • Posts

    186
  • Joined

  • Last visited

Everything posted by fantomel

  1. thank you for answering at this post.. i`ll give it a try see how i do things in php and flash and connect them read few tutorials over google.. and if i don't succeed alone. prob i`ll come back and ask around thank you again
  2. i was wondering is it possible to use php sockets with flash to create a multiplayer flash game? i've seen some servers free and paid for flash over the google but i would like to use something made by me and since i don't know java or c++. can anyone offer me some alternatives.. or ideas?
  3. i don't see any error in the code have you checked if you have any data in the table? does the table exists?
  4. yeah it depends a lot when you talk about region and sometimes is good to think about what public will enter that website from what countrys stuff like that.. or aim for one region.. etc. best choice is to use international stuff
  5. i think this might help you out. click here for the tutorial
  6. click y next go to: PHP OOP then go amazon or from where you get your books and get a book for OOP Principles or google about them and learn i haven't read much from that code because it's big and nasty but for each case should be a function(Method) then when it's parsed to the view depending on what user wants that method will be called you don't just throw in there all those cases and variables.
  7. he is putting that question because he is french and prob his name is something like jean luc "marosie" luc and marosie should go on the same row not on different rows. if the website you are building is strictly for france then go by the rules there(but it will affect the others) or go with standard ones.. First Name, Last Name and maybe include Middle Name or something like that.
  8. and if i would like to throw an error with file not found without triggering an error "class not found" how could i do ?
  9. hello guys i got a small questions.. does anyone have an idea how can i handle the errors for spl_autoload function? i don't have any idea how should i build the code for that.. to output an error when the files doesn't exist / class... can someone point me to an article about that without eval() ? or does anyone have an example ?
  10. try this one not if it's working wrote it on fly.. <?php error_reporting(E_ALL); ini_set('display_errors', 'On'); $mysql_server = 'localhost'; $mysql_username = 'userusername'; $mysql_password = 'yourpassword'; $mysql_db_name = 'yourdb'; $link = mysql_connect('$mysql_server', '$mysql_username', '$mysql_password'); if (!$link) { die('Could not connect: ' . mysql_error()); } else { $db = mysql_select_db($mysql_db_name); if(!$db = mysql_select_db($mysql_db_name)) { die('Could not choose database' . mysql_error()); } } if(isset($_POST['submit'])) { $email_to = $_POST['email_to']; $sql = "SELECT * FROM `login` WHERE `email` = '".$email_to."'"; $result = mysql_query($sql, $link) or die(mysql_error()); if(mysql_num_rows($result) == '1') { while($row = mysql_fetch_array($result, MYSQL_ASSOC)) { $username = $row['username']; $firname = $row['firstname']; $lastname = $row['lastname']; $email = $row['email']; $number = $row['number']; $street = $row['street']; $postcode = $row['postcode']; $town = $row['town']; $country = $row['country']; $telephone = $row['telephone']; $alternative_telephone = $row['alternative_telephone']; $title = $row['title']; } } else { echo "Ok mate, we got a problem here check the mysql connection"; if(!mysql_ping()) { echo "No connection to MySQL Database check your credentials."; exit; } } } // die() and exit() aren't the best solution they are many other solutions out there but for testing purpose i think it's a good choice good luck. ?>
  11. you are getting data from a form no ? if yes did you checked if the data comes from the $_POST ? i don't see there any type of checking for a submit....
  12. i apologise for posting something wrong i understand now thank you for correcting me. but still i have no idea about his problem. sorry again
  13. first of all what is your php version secondly how old is this phpbb version third did you check the functions on php.net/manual? i`m kinda of new to php i don't know everything about it but i've never meet before that type of coding. i think should be $user_ip = $_SEVER['REMOTE_ADDR']; echo $user_ip; this ones you should not really on them since they are deprecated click click use instead $_SERVER and for the second one $_ENV as for your problem i don't quite understand what you want to say. sorry. P.S if the above text it is incorrect or has mistakes please someone correct me or delete this post. thank you
  14. What if user disables javascript? it looks good to show the user an error after he input the data in form but if he disables he will be allowed to run any code he wants i've seen you told him to keep the php validation but i`m not sure he understood why ..(i remember when i was at the beginning i wanted to show the user the error but at the end i chosen the php validation and after that the validation using javascript) never really on javascript for such things always do a server side validation on everything that comes from other sources than you. you mustn't trust data from user.
  15. hello from my opinion doesn't matter how many tables are you can split them depending on your application or the way you want depending on what they have to do but if you want something nice you should take the cms from scratch clean it up improve the coding go on mvc if you like to have a separated code and so on.. each of us have different coding styles but in the end the code you build must be understood by the next programmer that will work on it so comment each part try making it readable easy to use and don't repeat the code
  16. thank you everyone for you replies to this post and for the advices they really helped me out on this part
  17. Sorry i was in hurry yesterday my internet connection at home is down .. and i didn't had time to post the right questions:D sorry again. ok so.. here it goes i`m building a simple browser based game like travian tribalwars ikariam... and i don't have any idea how should i build a map like those games have you can check on devana.eu an example of map i`m not sure what other details should i provide but i will wait for the next reply:-) thanks in advance
  18. Hello i`m trying to build a game from scratch but i`m kinda of lost on the part of creating the map. does anyone has an idea on how to create the map :-)?
  19. Hello can someone please explain to me how to display random records from a db? thank you
  20. Hello sorry for bordering you with such a stupid question but i can't figure it out. does each controller has his own view or what? can someone explain to me?
  21. Hello i've build up a css menu works perfectly in firefox latest version and safari and opera(same latest versions) but in ie7 and ie8 doesn't display correctly the menu from the mouse over is not displaying correctly and and i can't find a solution to fix it maybe someone around here with more experience could help me ? ul.menu { float:left; list-style-type:none; width:330px; margin:10px auto; } ul.menu li { padding:0; float:left; margin:0; } ul.menu li a { display:inline; font-weight:normal; line-height:35px; margin-left:10px; } ul.menu li a:hover, .menu ul li:hover a { text-decoration:none; } ul.rightmenu li ul {display:none; height:auto; padding:0px; margin:0px; border:0px; position:absolute; width:225px; z-index:200; top:4.5em; margin-left: auto; margin-right: auto;/*left:0;*/ } ul.rightmenu li:hover ul { display:block; } ul.menu ul li { display:inline; float:none; margin:0px; padding:0px; width:230px; margin-top: -11px;} ul.rightmenu li:hover li a { background:none; } ul.menu li ul a { display:inline; height:35px; font-size:12px; font-style:normal; margin:0; padding:0; } ul.menu li ul a:hover, ul.menu li ul li:hover a { border:0px; color:#ffffff; text-decoration:none; } ul.menu p { clear:left; } ul.rightmenu { float: right; list-style-type:none; margin:10px 90px 0 0; padding:0; } ul.rightmenu li { display: inline; padding:0; margin:0; } HTML CODE <ul class="menu"> <li><a href="index.php?url=home&lang=en" ><img src="resources/img/layout/home_03.png" alt="Home" /></a></li> <li><a href="index.php?url=howto&lang=en"><img src="resources/img/layout/how_to_03.png" alt="How We Do" /></a></li> <li><a href="index.php?url=quality&lang=en"><img src="resources/img/layout/quality_03.png" alt="Quality Control" /></a></li> <li><a href="index.php?url=gallery&lang=en"><img src="resources/img/layout/gallery_03.png" alt="Gallery" /></a></li> </ul> <ul class="rightmenu"> <li><a href="index.php?url=credentials&lang=en"><img src="resources/img/layout/credentials_03.png" alt="Credentials" /></a></li> <li><a href="" ><img src="resources/img/layout/products_03.png" alt="Products" /></a> <ul> <li><a href="index.php?url=buy_products&lang=en"><img src="resources/img/layout/buy_products_03.png" alt="Buy Products" /></a></li></a> <li><a href="index.php?url=buy_waste&lang=en"><img src="resources/img/layout/buy_waste_03.png" alt="Waste Buy" /></a></li> </ul> </li> <li><a href="index.php?url=contact&lang=en"><img src="resources/img/layout/contact_03.png" alt="Contact" /></a></li> </ul> <div id="logo"><img src="../resources/img/layout/logo_home.png" /></div>
  22. Good Morning yeah i know until know i used the global $_GET var but after watching over the code ignite framework zend and others i've seen they have another option for building urls ... url segments i thinks it's called and i would i would to learn how to build a class for those type urls for the moment i've only written code for the part of requesting url and making as an array but from here on i didn't quite understand how things should connect :-? and that's why i came here maybe someone has build from scratch a similar class and point me in a direction or show me a basic example...
  23. Hello does anyone build from scratch a url routing system? or anyone can help me understand it better because from what i found on google nothing was clearly explained to me .
  24. yeah was thinking on that had the same problem few days ago writing code and when i saved i accidentally changed the type for saving the file and the server didn't run the code... but i don't know what to say on localhost on xampp works perfect the same code..i`ll give a shot as you said and i will come back with news..
×
×
  • 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.