Thread: Simple donation [works with martins donation server sided code]

Page 1 of 3 123 LastLast
Results 1 to 10 of 25
  1. #1 Simple donation [works with martins donation server sided code] 
    Unfortunately we’re all human. Except me


    Join Date
    Aug 2011
    Posts
    926
    Thanks given
    539
    Thanks received
    439
    Rep Power
    601
    Hello,

    Martins donate system links are dead thats why i decided to "remake" it

    Its realy simple code and ipn is as simple as it can get so dont rage..

    LINK TO SERVER SIDED CODE: http://www.rune-server.org/runescape...on-system.html

    LINK TO WEBSITE CODE DOWNLOAD: http://blanked-studios.info/test/class.zip

    LIVE PREVIEW: http://blanked-studios.info/test


    Ok if you downloaded files, create mysql user and database. Go in class file and edit database.class.php . Change database connect details to yours.
    When that is done go to phpmyadmin and create this table:

    Code:
    CREATE TABLE IF NOT EXISTS `donation` (
      `username` varchar(32) NOT NULL,
      `time` varchar(100) NOT NULL,
      `productid` varchar(100) NOT NULL,
      `price` decimal(10,0) NOT NULL,
      `tickets` int(11) NOT NULL,
      `index` int(11) NOT NULL AUTO_INCREMENT,
      PRIMARY KEY (`index`)
    ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
    Now when your database is set up, its time to set up donation itself!

    Edit index.php and change next defines:

    PAYPAL_EMAIL = email where you want to recieve payments to
    PAYPAL_RETURN_URL = url where paypal will redict user if payment is sucessfull/unsucessfull
    PAYPAL_IPN_URL = url to ipn file which is located in class folder. Example: http://blanked-studios.info/test/class/ipn.php

    How do I add rewards?
    Adding rewards is realy simple, all you have to do is add new option in form.

    Code:
    <option value="3">Purple phat</option>
    value is product id! Remember that because you will need it later.

    So now when item is added to form, you have to add it to array.

    Code:
    $rewards = array
    		   (
    		   array("REWARD PRICE", "REWARD NAME"),
    		   array(12, "Dragon Claws"), // Reward 1
    		   array(13, "Armadyl Godsword"), // Reward 2
    		   array(14, "Purple phat"), // Etc..
    		   );
    As you can see first value in array is reward price . If you for example set it to 10, reward will cost 10$ .
    Second value is reward name.

    When adding rewards make sure you dont delete this row:

    Code:
    array("REWARD PRICE", "REWARD NAME"),
    because if you do, it wont work anymore

    Thats all for now, if you like it leave a thanks and if you need help feel free to ask me

    For those who dont like current IPN, I'll write new one. This one looks like that because I didnt have time to make it better

    Credits: Web sided: to me
    Server sided to martin ofc

    Reply With Quote  
     

  2. Thankful users:


  3. #2  
    Software Developer

    Tyrant's Avatar
    Join Date
    Jul 2013
    Age
    24
    Posts
    1,562
    Thanks given
    678
    Thanks received
    423
    Rep Power
    1060
    Some media won't hurt, otherwise great tutorial!
    Reply With Quote  
     

  4. Thankful user:


  5. #3  
    Banned
    Join Date
    Aug 2015
    Age
    29
    Posts
    142
    Thanks given
    42
    Thanks received
    43
    Rep Power
    0
    Nice work Luka, hope some uses this
    Reply With Quote  
     

  6. Thankful user:


  7. #4  
    anInt69

    Max _'s Avatar
    Join Date
    Feb 2012
    Age
    26
    Posts
    1,801
    Thanks given
    426
    Thanks received
    727
    Rep Power
    599
    Good job on this.
    Reply With Quote  
     

  8. Thankful user:


  9. #5  
    Coding coding coding...

    Ivo's Avatar
    Join Date
    Mar 2008
    Age
    33
    Posts
    1,425
    Thanks given
    30
    Thanks received
    147
    Rep Power
    2017
    I remember, original post by Martin, users did not save in database. Does this have same problem?
    Used it while i hosted private server, was way better than rsps-com script and had no problems with it.
    Tried to fix original one few days ago but seems like its outdated and doesnt work anymore
    Thamks for this

    Backup http://www.upload.ee/files/5051328/class.zip.html

    Quote Originally Posted by LukaFurlan View Post
    Hello,

    Martins donate system links are dead thats why i decided to "remake" it

    Its realy simple code and ipn is as simple as it can get so dont rage..

    LINK TO SERVER SIDED CODE: http://www.rune-server.org/runescape...on-system.html

    LINK TO WEBSITE CODE DOWNLOAD: http://blanked-studios.info/test/class.zip

    LIVE PREVIEW: http://blanked-studios.info/test


    Ok if you downloaded files, create mysql user and database. Go in class file and edit database.class.php . Change database connect details to yours.
    When that is done go to phpmyadmin and create this table:

    Code:
    CREATE TABLE IF NOT EXISTS `donation` (
      `username` varchar(32) NOT NULL,
      `time` varchar(100) NOT NULL,
      `productid` varchar(100) NOT NULL,
      `price` decimal(10,0) NOT NULL,
      `tickets` int(11) NOT NULL,
      `index` int(11) NOT NULL AUTO_INCREMENT,
      PRIMARY KEY (`index`)
    ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;
    Now when your database is set up, its time to set up donation itself!

    Edit index.php and change next defines:

    PAYPAL_EMAIL = email where you want to recieve payments to
    PAYPAL_RETURN_URL = url where paypal will redict user if payment is sucessfull/unsucessfull
    PAYPAL_IPN_URL = url to ipn file which is located in class folder. Example: http://blanked-studios.info/test/class/ipn.php

    How do I add rewards?
    Adding rewards is realy simple, all you have to do is add new option in form.

    Code:
    <option value="3">Purple phat</option>
    value is product id! Remember that because you will need it later.

    So now when item is added to form, you have to add it to array.

    Code:
    $rewards = array
    		   (
    		   array("REWARD PRICE", "REWARD NAME"),
    		   array(12, "Dragon Claws"), // Reward 1
    		   array(13, "Armadyl Godsword"), // Reward 2
    		   array(14, "Purple phat"), // Etc..
    		   );
    As you can see first value in array is reward price . If you for example set it to 10, reward will cost 10$ .
    Second value is reward name.

    When adding rewards make sure you dont delete this row:

    Code:
    array("REWARD PRICE", "REWARD NAME"),
    because if you do, it wont work anymore

    Thats all for now, if you like it leave a thanks and if you need help feel free to ask me

    For those who dont like current IPN, I'll write new one. This one looks like that because I didnt have time to make it better

    Credits: Web sided: to me
    Server sided to martin ofc
    Reply With Quote  
     

  10. #6  
    Unfortunately we’re all human. Except me


    Join Date
    Aug 2011
    Posts
    926
    Thanks given
    539
    Thanks received
    439
    Rep Power
    601
    Quote Originally Posted by Ivo View Post
    I remember, original post by Martin, users did not save in database. Does this have same problem?
    Used it while i hosted private server, was way better than rsps-com script and had no problems with it.
    Tried to fix original one few days ago but seems like its outdated and doesnt work anymore
    Thamks for this

    Backup UPLOAD.EE - class.zip - Download
    Users save fine Everything saves except for tickets and time.. I dont realy know why they even exist lol
    Reply With Quote  
     

  11. #7  
    Coding coding coding...

    Ivo's Avatar
    Join Date
    Mar 2008
    Age
    33
    Posts
    1,425
    Thanks given
    30
    Thanks received
    147
    Rep Power
    2017
    True. Thanks
    Reply With Quote  
     

  12. #8  
    So when I'm free, I'm free


    Jay Gatsby's Avatar
    Join Date
    Jun 2010
    Posts
    2,307
    Thanks given
    1,148
    Thanks received
    1,982
    Rep Power
    5000
    Does this have the same exploit that Martin's did?

    Good work on this, nice to see you contribute to the community.


    All the best,
    Harry
    Reply With Quote  
     

  13. #9  
    anInt69

    Max _'s Avatar
    Join Date
    Feb 2012
    Age
    26
    Posts
    1,801
    Thanks given
    426
    Thanks received
    727
    Rep Power
    599
    Quote Originally Posted by Jay Gatsby View Post
    Does this have the same exploit that Martin's did?

    Good work on this, nice to see you contribute to the community.


    All the best,
    Harry
    It's not Martins, it's just built with the same SQL layout so that the code he(Martin) released could work with his(Luka's) system.
    Reply With Quote  
     

  14. Thankful user:


  15. #10  
    So when I'm free, I'm free


    Jay Gatsby's Avatar
    Join Date
    Jun 2010
    Posts
    2,307
    Thanks given
    1,148
    Thanks received
    1,982
    Rep Power
    5000
    Quote Originally Posted by Max _ View Post
    It's not Martins, it's just built with the same SQL layout so that the code he(Martin) released could work with his(Luka's) system.
    Oh right gotcha.
    Reply With Quote  
     

Page 1 of 3 123 LastLast

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Similar Threads

  1. Replies: 0
    Last Post: 03-24-2015, 08:02 PM
  2. Replies: 16
    Last Post: 10-14-2013, 03:01 AM
  3. Replies: 0
    Last Post: 04-10-2011, 01:18 PM
  4. Replies: 0
    Last Post: 06-26-2010, 02:09 PM
  5. Replies: 2
    Last Post: 12-05-2008, 03:05 AM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •