Jump to content
MakeWebGames

[mccode v2] Profile Image Uploader


Isomerizer

Recommended Posts

Hey, made this mod for my game, so as usual i'll post here, Works fine for me... this mod will add an image upload for profile pics on your game, to stop several exploits, This improves security (hopefully) :P.

Follow th below instructions and it should go fine.

Update ASAP, Mass security updates have been added.

Updates:

-Code stripped from files uploaded.

-Will stop bad file extensions, such as shells.

-2nd Security update.

-Only one image can be on the web server per user.

-Images cannot be used more then twice to save space.

-Crons / Extra SQL is no longer needed.

-Security update.

-Variables Fixed.

Before you do the below on your FTP under public_html create a new directory called "profilepics" with the CHMOD permissions set to 757.

Create uploadpic.php with the code:

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Open preferences.php and change

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

To...

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Delete from preferences.php

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

For extra security, "profilepics" directory can be stopped from executing any script.

Create sseccath. <- (spelt backwards, as CE wont allow the word) with:

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

and place in "profilepics".

Can be seen working @ www.amazon-survival.com

Link to comment
Share on other sites

  • Replies 83
  • Created
  • Last Reply

Top Posters In This Topic

Re: [Free] [v1] Profile Image Uploader

 

Few Details: Max 2 uploads a day to stop spam, size can be edited, file extentions can be added.

The rest is self-explanatory.

ah ok.

Sorry, couldn't bother reading it all. Simply assumed it would only allow the user to host a single profile pic on the server, and when they upload a new one it would delete the old one.

Seems the most efficient way to me.

@iso - check out the php unlink() function m8

Link to comment
Share on other sites

Re: [Free] [v1] Profile Image Uploader

 

ah ok.

Sorry, couldn't bother reading it all. Simply assumed it would only allow the user to host a single profile pic on the server, and when they upload a new one it would delete the old one.

Seems the most efficient way to me.

@iso - check out the php unlink() function m8

Thanks seanybob ive updated the script now so it runs better :)

 

The profilepics folder will also need to be chmodded 666 or 777 to allow the script to write to it.

It still works if it isnt set to 666 / 777

Link to comment
Share on other sites

Re: [Free] [v1] Profile Image Uploader

 

Hey, made this mod for my game, so as usual i'll post here, Works fine for me... this mod will add an image upload for profile pics on your game, to stop several exploits, This improves security (hopefully) :P.

Follow th below instructions and it should go fine.

Updates:

-Only one image can be on the web server per user

-Images cannot be used more then twice to save space

-Crons / Extra sql is no longer needed

-Security update

-Variables Fixed

Few Details: Size can be edited, File extentions can be added.

Enjoy....

Before you do the below on your FTP under public_html create a new directory called "profilepics"

Create uploadpic.php with the code:

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Open preferences.php and change

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

To...

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Delete from preferences.php

 

You're unable to view this code.

Viewing code within this forum requires registration, you can register here for free.

 

Can be seen working @ www.amazon-survival.com

Nice..+1

Link to comment
Share on other sites

Re: [Free] [v1] Profile Image Uploader

 

i dont get where to put profilepics ???

 

Before you do the below on your FTP under public_html create a new directory called "profilepics"

Open up your FTP server, wait until it connects, then double click public_html. Then create a new file / directory in there called "profilepics" and it should work fine. :wink:

Link to comment
Share on other sites

  • 2 weeks later...
  • 2 weeks later...
  • 5 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...