Script Requests

This is guide mostly for website tools and code, for example CMS or registration scripts.
There can also be tools.

Moderators: osRose dev team, ospRose dev team, osiRose dev team, Moderators

Script Requests

Postby Ultra on Wed Mar 21, 2012 9:03 pm

1) Who can make or Do it is possible to make register with more functions like to create the character too? (ex. Male or Female , Name ,)
2) Hmm i really wanna to know how can i make a signature creator/ viewer (like in arua)
3)Do the Storage script is done ?
4)Do someone can give me and script (news) that you can see from who is writed (author) ?
5)Do someone can give me a script (news) that you can reply to the news ?
6)How i can make that you can choise refine for the armors/fun sets (like in Item Mall 1 i think)
7)Do someone can give me a scipt where you can make a clan? (From the website)
Last edited by Ultra on Thu Mar 22, 2012 4:32 pm, edited 1 time in total.
Ultra
Rackie
Rackie
 
Posts: 225
Joined: Thu Jul 22, 2010 6:31 pm
Location: Usa

Re: Script Requests

Postby Mark on Thu Mar 22, 2012 1:05 pm

Ultra wrote:1) Who can make or Do it is possible to make register with more functions like to create the character too? (ex. Male or Female , Name ,)

The Register Script Creates the base account, so take a look in the php for it and see how it inputs data into the sql table, i'm sure you could make a simple php script for it to create a character, you'd have to pull the right table data from the "characters.sql" to do this though.
Ultra wrote:2) Hmm i really wanna to know how can i make a signature creator/ viewer (like in arua)

Sig Creator? as in Forum type of signatures?
Ultra wrote:3)Do the Storage script is done ?

Iv'e been busy working on my own client and server the past week or so, I'm hoping I wont be the only one to work on the Storage script ( *pokes Hoegarden and others ) as this would be a great community release, I'll start working again on it soon and post results into a thread.
Ultra wrote:4)Do someone can give me and script (news) that you can see from who is writed (author) ?

There is a News script which comes with the IceDynasty layout in its modules folder
Ultra wrote:5)Do someone can give me a script (news) that you can reply to the news ?

Not sure about replying to it though, maybe you should use a forum for this, as it would be much easier for users to reply to rather than using up lots of your hosting accounts bandwidth everytime someone reply's to a message or reloads the page.
Ultra wrote:6)How i can make that you can choise refine for the armors/fun sets (like in Item Mall 1 i think)

There should be a Column called "Ref_Able" in the sql table for your Item mall, simple change the number 0 to whatever refine you want it set at when the customer purchases the item.
*p.s: Soc_able determines weather the item comes with a slot or not too.
Administrator / Coder for EutopiaRose Online
Image
http://www.eutopiarose.co.uk
User avatar
Mark
Rackie
Rackie
 
Posts: 176
Joined: Tue Dec 13, 2011 8:15 am
Location: Sunny England

Re: Script Requests

Postby Mark on Thu Mar 22, 2012 3:27 pm

Just having a few issues when collecting data from the sql tables.

So far iv'e got:
  1. <html>
  2. <body>
  3. <?php
  4. if(!session_is_registered(User_Name)) {
  5. die('You must be logged in to view your storage!');
  6. }
  7.  
  8. if(!session_is_registered(User_Pass)) {
  9. die('You must be logged in to view your storage!');
  10. }
  11. mysql_connect($dbhost, $dbuser, $dbpasswd);
  12. mysql_select_db($dbname) or die( "Unable to connect to database");
  13.  
  14. $query="SELECT * FROM storage";
  15. $result=mysql_query($query);
  16. $num=mysql_numrows($result);
  17. mysql_close();
  18. ?>
  19. <table border="0" cellspacing="2" cellpadding="2">
  20. <tr>
  21. <th><font face="Arial, Helvetica, sans-serif">owner</font>
  22. </th>
  23. <th><font face="Arial, Helvetica, sans-serif">itemnum</font></th>
  24. <th><font face="Arial, Helvetica, sans-serif">itemtype</font></th>
  25. <th><font face="Arial, Helvetica, sans-serif">refine</font></th>
  26. <th><font face="Arial, Helvetica, sans-serif">stats</font></th>
  27. </tr>
  28.  
  29. <?php
  30. $i=0;
  31. while ($i < $num) {
  32.  
  33. $f1=mysql_result($result,$i,"owner");
  34. $f2=mysql_result($result,$i,"itemnum");
  35. $f3=mysql_result($result,$i,"itemtype");
  36. $f4=mysql_result($result,$i,"refine");
  37. $f5=mysql_result($result,$i,"stats");
  38. ?>
  39.  
  40. <tr>
  41. <td><font face="Arial, Helvetica, sans-serif"><?php echo $f1; ?></font></td>
  42. <td><font face="Arial, Helvetica, sans-serif"><?php echo $f2; ?></font></td>
  43. <td><font face="Arial, Helvetica, sans-serif"><?php echo $f3; ?></font></td>
  44. <td><font face="Arial, Helvetica, sans-serif"><?php echo $f4; ?></font></td>
  45. <td><font face="Arial, Helvetica, sans-serif"><?php echo $f5; ?></font></td>
  46. </tr>
  47.  
  48. <?php
  49. $i++;
  50. }
  51. ?>
  52. </body>
  53. </html>


What i need to figure out is what WHERE statement to use, Iv'e tried using WHERE owner = '".$_SESSION['account'].";
and
WHERE owner = '".$_SESSION['owner'].";

But so far it just keeps on displaying ALL of the users on the server' storage contents, the way it works so far is that users log in > there user panel comes up > they click the link to take them to storage > then the storage is displayed.

Any ideas on a sql filter please?

Thanks
Administrator / Coder for EutopiaRose Online
Image
http://www.eutopiarose.co.uk
User avatar
Mark
Rackie
Rackie
 
Posts: 176
Joined: Tue Dec 13, 2011 8:15 am
Location: Sunny England

Re: Script Requests

Postby xadet3 on Thu Mar 22, 2012 3:43 pm

At the top of your page put
  1. print_r($_SESSION);
  2. die();

and paste here what it returns.
xadet3
Pero pero
Pero pero
 
Posts: 727
Joined: Tue Jan 08, 2008 11:51 pm
Location: Norwich, England.

Re: Script Requests

Postby hoegarden31 on Thu Mar 22, 2012 6:10 pm

Maybe it's because owner in the storage table is the ID of the user. not his name :D
So try $_SESSION['account_id']...
I'm the one and only. In heaven and on earth.
Image
hoegarden31
Rackie
Rackie
 
Posts: 150
Joined: Sun Nov 13, 2011 7:13 pm

Re: Script Requests

Postby Mark on Thu Mar 22, 2012 8:54 pm

xadet3 wrote:At the top of your page put
  1. print_r($_SESSION);
  2. die();

and paste here what it returns.


As requested:
  1. Array ( [User_Name] => [User_Pass] => [account] => Mark [account_id] => 84 )


Is whats being printed.

@hoegarden31: I'll try that now too.
Administrator / Coder for EutopiaRose Online
Image
http://www.eutopiarose.co.uk
User avatar
Mark
Rackie
Rackie
 
Posts: 176
Joined: Tue Dec 13, 2011 8:15 am
Location: Sunny England

Re: Script Requests

Postby Ultra on Thu Mar 22, 2012 9:03 pm

It would be GREAT if you share the script :) !
But do it will have a design like in speed rose ?
Or it will be as a text or so .. ?
Ultra
Rackie
Rackie
 
Posts: 225
Joined: Thu Jul 22, 2010 6:31 pm
Location: Usa

Re: Script Requests

Postby Mark on Thu Mar 22, 2012 9:12 pm

We'll share the script when its finished ;)

And Yeah im hoping we could possibly have a UI similar to that used in-game

@hoegarden31:

Tried that .$_SESSION['account_id'] the full statement was:
  1. $query="SELECT * FROM storage WHERE owner = ".$_SESSION['account_id']."'");


Could an If statement be used instead of the WHERE filter, i.e
  1. $query="SELECT * FROM storage WHERE owner = ".$_SESSION['account_id']."'");
  2. if ($S_SESSION['account_id']) < owner
  3. {
  4. die ();
  5. }


I dunno, i'm just shooting blindly and hoping for a "Success"
Administrator / Coder for EutopiaRose Online
Image
http://www.eutopiarose.co.uk
User avatar
Mark
Rackie
Rackie
 
Posts: 176
Joined: Tue Dec 13, 2011 8:15 am
Location: Sunny England

Re: Script Requests

Postby Ultra on Thu Mar 22, 2012 10:20 pm

I will say you Good Luck :) ! Because these months dont have new scripts ..
Tha last tool was the map viewer (i think) ... but i will wait when xadet finish him new tools for the community :) !
I will try to realese something too soon :) ( im not PRO xD) :D
Ultra
Rackie
Rackie
 
Posts: 225
Joined: Thu Jul 22, 2010 6:31 pm
Location: Usa

Re: Script Requests

Postby Mark on Fri Mar 23, 2012 7:19 pm

Mini Bump:

@Xadet, as requested this is whats being printed



  1. LINE NUMBER ON/OFF | EXPAND/CONTRACT | SELECT ALL
  2. Array ( [User_Name] => [User_Pass] => [account] => Mark [account_id] => 84 )



Thanks
Administrator / Coder for EutopiaRose Online
Image
http://www.eutopiarose.co.uk
User avatar
Mark
Rackie
Rackie
 
Posts: 176
Joined: Tue Dec 13, 2011 8:15 am
Location: Sunny England

Next

Return to PHP / Web Guides, Scripts and tools.

Who is online

Users browsing this forum: No registered users and 2 guests