tittlemouse Posted October 11, 2008 Share Posted October 11, 2008 on index.php find $exp=(int)($ir['exp']/$ir['exp_needed']*100); after add if ( !$ir['married'] ) { $marital="<font color='red'>No</font>"; } else { $k=mysql_query("SELECT username FROM users WHERE userid={$ir['married']}", $c); $marital="".mysql_result($k,0,0)." "; $marital.="[Manage]"; $mair=mysql_query("SELECT u.*, h.* FROM users u LEFT JOIN houses h ON h.hWILL=u.maxwill WHERE userid={$ir['married']}",$c); $ms=mysql_fetch_array($mair); } if ($ir['married']>0) { $marr=mysql_query("SELECT * FROM users WHERE userid={$ir['married']}",$c); $ma=mysql_fetch_array($marr); if ($ma['willmax']>$ir['maxwill']) { mysql_query("UPDATE users SET maxwill={$ma['willmax']} WHERE userid=$userid",$c); } if ($ir['willmax']<$ir['maxwill'] && $ir['maxwill']>$ma['willmax']) { mysql_query("UPDATE users SET maxwill=willmax WHERE userid=$userid",$c); } } if ($ir['maxwill']<$ir['willmax']) { mysql_query("UPDATE users SET maxwill=willmax WHERE userid=$userid",$c); } if ($ir['married']==0 && $ir['maxwill']>$ir['willmax']) { mysql_query("UPDATE users SET maxwill=willmax WHERE userid=$userid",$c); } Quote Link to comment Share on other sites More sharing options...
Tezza` Posted October 11, 2008 Share Posted October 11, 2008 Re: can someone convert this to v2 Start and use the search box, instead of being lazy.... Here you go.. http://criminalexistence.com/ceforums/index.php?topic=16666.0 Quote Link to comment Share on other sites More sharing options...
Floydian Posted October 11, 2008 Share Posted October 11, 2008 Re: can someone convert this to v2 generally, most things on version 1 work on version 2 so long as the includes at the beginning of the script are changed. (going from v2 to v1 is a different story) It should work as is since this is just a part of a script. Quote Link to comment Share on other sites More sharing options...
tittlemouse Posted October 11, 2008 Author Share Posted October 11, 2008 Re: can someone convert this to v2 can someone import this into a index code for v2 Quote Link to comment Share on other sites More sharing options...
Kaotic Posted October 11, 2008 Share Posted October 11, 2008 Re: can someone convert this to v2 on index.php find $exp=(int)($ir['exp']/$ir['exp_needed']*100); after add if ( !$ir['married'] ) { $marital="<font color='red'>No</font>"; } else { $k=$db->query("SELECT username FROM users WHERE userid={$ir['married']}", $c); $marital="[url='viewuser.php?u={$ir[']".mysql_result($k,0,0)."[/url] "; $marital.="[[url='partner.php']Manage[/url]]"; $mair=$db->query("SELECT u.*, h.* FROM users u LEFT JOIN houses h ON h.hWILL=u.maxwill WHERE userid={$ir['married']}",$c); $ms=mysql_fetch_row($mair); } if ($ir['married']>0) { $marr=$db->query("SELECT * FROM users WHERE userid={$ir['married']}",$c); $ma=mysql_fetch_row($marr); if ($ma['willmax']>$ir['maxwill']) { $db->query("UPDATE users SET maxwill={$ma['willmax']} WHERE userid=$userid",$c); } if ($ir['willmax']<$ir['maxwill'] && $ir['maxwill']>$ma['willmax']) { $db->query("UPDATE users SET maxwill=willmax WHERE userid=$userid",$c); } } if ($ir['maxwill']<$ir['willmax']) { $db->query("UPDATE users SET maxwill=willmax WHERE userid=$userid",$c); } if ($ir['married']==0 && $ir['maxwill']>$ir['willmax']) { $db->query("UPDATE users SET maxwill=willmax WHERE userid=$userid",$c); } Not tested but it should work Quote Link to comment Share on other sites More sharing options...
Tezza` Posted October 12, 2008 Share Posted October 12, 2008 Re: can someone convert this to v2 can someone import this into a index code for v2 Tittlemouse, if you want to be a good developer / programmer, you need to learn to do these things for yourself, and do the research for yourself, im sure you can find all you need here on the forums and if not there is always google and as a last resort yes you can post on the forum, but your asking people to do simple things that anyone could do which i know for a fact are on the forums. Quote Link to comment Share on other sites More sharing options...
tittlemouse Posted October 12, 2008 Author Share Posted October 12, 2008 Re: can someone convert this to v2 true you are right tezza. i am a rubbish coder and i will not learn nothing if i do not try, is there a mccodes coding guide somewhere on this forum so i can learn and code for myself it is about time that i stop relying on other members to do what i should learn Quote Link to comment Share on other sites More sharing options...
Floydian Posted October 12, 2008 Share Posted October 12, 2008 Re: can someone convert this to v2 mccodes guide? You need a php guide, an html guide, a mysql guide, and maybe a javascript guide. HTML is most important, since your users will see nothing without html. PHP is the next one because it connects mysql to the html. javascript is the last one because you could do without it completely. Quote Link to comment Share on other sites More sharing options...
tittlemouse Posted October 12, 2008 Author Share Posted October 12, 2008 Re: can someone convert this to v2 ok her i go i dont know html that good i dont know php- i have a book php-5-for-dummies i dont know mysql but i do want to learn Quote Link to comment Share on other sites More sharing options...
Tezza` Posted October 12, 2008 Share Posted October 12, 2008 Re: can someone convert this to v2 Browse the 'net. [*]http://w3schools.com [*]http://php.net Quote Link to comment Share on other sites More sharing options...
tittlemouse Posted October 12, 2008 Author Share Posted October 12, 2008 Re: can someone convert this to v2 wow w3schools.com is a great site i will start with html and css and when i am good at that i will move on. if i am a total noob how long you think i will need to learn? Quote Link to comment Share on other sites More sharing options...
Tezza` Posted October 12, 2008 Share Posted October 12, 2008 Re: can someone convert this to v2 As long as it takes, there is no rush, as long as you get it right ;). Quote Link to comment Share on other sites More sharing options...
mdshare Posted October 13, 2008 Share Posted October 13, 2008 Re: can someone convert this to v2 wow w3schools.com is a great site i will start with html and css and when i am good at that i will move on. if i am a total noob how long you think i will need to learn? forever simple as it is just start with the primary basic requirement which is * Learn to read and understand a html script , if you can do that you are already a step further reading and understanding is not oh table well that's a table with some text in and you can give it a border it's understanding what the usage actually is and what all possible attributes are and what they do. I'm sure a ton doesn't even now what cellpading and cellspacing is not even thinking on how the majority would explain the rules attribute. Off course there are easy ones that doesn't need brains like event attributes as these are self explaining. Now html will also help you understanding mysql better as weird as it sounds The table structure in html is basicly a database setup, table, columns, rows but that structure can be found everywhere most fail with mysql as they just doesn't know the basic structure of a database. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.