Jump to content



Photo

WordPress Watermark Plugin?

php

  • Please log in to reply
24 replies to this topic

#16 palenous

palenous

    Neowinian

  • Joined: 19-January 13
  • Location: Ohio, United States
  • OS: Windows 7 Ultimate
  • Phone: Samsung Galaxy SIII (Verizon)

Posted 01 February 2013 - 17:52

Well, this is probably something you would want to happen to the image as soon as it's uploaded. If it's just png and jpg, it shouldn't be very difficult at all, but I actually meant the code that handles the upload, not the code that displays the image after it's uploaded. If you would rather do this to the image per request, that is possible as well, but not as clean...


#17 OP Mr.XXIV

Mr.XXIV

    Shine bright like Iron Man.

  • Tech Issues Solved: 1
  • Joined: 30-April 11
  • Location: Durham, North Carolina
  • OS: OS X Mountain Lion 10.8.5
  • Phone: iPhone 5

Posted 01 February 2013 - 19:04

Well, this is probably something you would want to happen to the image as soon as it's uploaded. If it's just png and jpg, it shouldn't be very difficult at all, but I actually meant the code that handles the upload, not the code that displays the image after it's uploaded. If you would rather do this to the image per request, that is possible as well, but not as clean...


This is what I'll be using, I used to have it fully modified. It's basically a plugin that utilizes the custom post type and whatnot for WordPress.

Attached Files



#18 palenous

palenous

    Neowinian

  • Joined: 19-January 13
  • Location: Ohio, United States
  • OS: Windows 7 Ultimate
  • Phone: Samsung Galaxy SIII (Verizon)

Posted 01 February 2013 - 22:21

Hm...what is the media_handle_upload() function in submit_user_images.php on line 171? I can't seem to find it and I believe that is where the image data is actually being handled.

#19 n_K

n_K

    Neowinian Senior

  • Tech Issues Solved: 3
  • Joined: 19-March 06
  • Location: here.
  • OS: FreeDOS
  • Phone: Nokia 3315

Posted 01 February 2013 - 22:26

It'll only just tell me the same thing Watermark Reloaded does in that manual.

I've had the pro version of Watermark Reloaded before, and it only adds the watermark on top of the image. I want it added under, just like 9GAG where it can be hidden until someone tries to take the image.

You know what the actual idea of programming is, right? You learn how to code and make things do what you want. You seem to do the hacking idea, well not even that actually - more 'what I needs exist, I do not need to know how it works and cannot make any of it myself'... You will not get far like that in programming at all, in fact if you take a course in programming you'd fail the first test and be kicked out.
Bad programmers copy and paste.
Good programmers write their own code.
Great programmers write their own code, and recheck it and search/plan for areas that might have problems.
Programmers that are the bad link in companies and leave large gaping security holes and broken sites/features are those that don't even know what they're doing, and right now you fit into this category.

Making the watermark appear below the image on something that it overlays over the top is so simple that if you read the PHP GD guide (if you haven't then you shouldn't be doing ANY manipulation of images at all in PHP) it'd be probably 2 lines of code that you'd change in the whole thing, and you'd know exactly what lines to search for too.

#20 OP Mr.XXIV

Mr.XXIV

    Shine bright like Iron Man.

  • Tech Issues Solved: 1
  • Joined: 30-April 11
  • Location: Durham, North Carolina
  • OS: OS X Mountain Lion 10.8.5
  • Phone: iPhone 5

Posted 02 February 2013 - 01:45

Hm...what is the media_handle_upload() function in submit_user_images.php on line 171? I can't seem to find it and I believe that is where the image data is actually being handled.


The image handles are still worked through WordPress' core. That's where I'd have trouble too.

Function: http://codex.wordpre...a_handle_upload

You know what the actual idea of programming is, right? You learn how to code and make things do what you want. You seem to do the hacking idea, well not even that actually - more 'what I needs exist, I do not need to know how it works and cannot make any of it myself'... You will not get far like that in programming at all, in fact if you take a course in programming you'd fail the first test and be kicked out.
Bad programmers copy and paste.
Good programmers write their own code.
Great programmers write their own code, and recheck it and search/plan for areas that might have problems.
Programmers that are the bad link in companies and leave large gaping security holes and broken sites/features are those that don't even know what they're doing, and right now you fit into this category.

Making the watermark appear below the image on something that it overlays over the top is so simple that if you read the PHP GD guide (if you haven't then you shouldn't be doing ANY manipulation of images at all in PHP) it'd be probably 2 lines of code that you'd change in the whole thing, and you'd know exactly what lines to search for too.


Can you stop? Honestly, if this was plain PHP, I'd honestly work a little harder on it because It's more natural to code on, but this is WordPress, I have to comply with the core functions, nevertheless the security I have to ensure. I have priorities right now to build off what I can until I can refine what's most suitable for me.There's a reason why there's a community of developers. Real programmers help each other out.

#21 n_K

n_K

    Neowinian Senior

  • Tech Issues Solved: 3
  • Joined: 19-March 06
  • Location: here.
  • OS: FreeDOS
  • Phone: Nokia 3315

Posted 02 February 2013 - 01:58

but this is WordPress, I have to comply with the core functions, nevertheless the security I have to ensure. I have priorities right now to build off what I can until I can refine what's most suitable for me.There's a reason why there's a community of developers. Real programmers help each other out.

You've listed 2 WP plugins that do it but don't position it correctly, I've linked you to the OFFICIAL PHP guide for how images are manipulated in PHP, if you had any clue about PHP you'd be able to read it and notice that you need to alter a few lines in the existing plugins to get what you want, it is NOT HARD, in fact it's VERY basic PHP-GD, the functions to search for are all listed on the page.
Don't say it's because it's wordpress, you can't do it when a simple solution exists. Try the simple solution instead of repeatedly bashing it and you might learn some PHP in the process.

EDIT: In fact, the http://wordpress.org...rmark-reloaded/ plugin which was mentioned previously says it can already do this;
'Watermark outside picture'.

Edited by n_K, 02 February 2013 - 02:02.


#22 OP Mr.XXIV

Mr.XXIV

    Shine bright like Iron Man.

  • Tech Issues Solved: 1
  • Joined: 30-April 11
  • Location: Durham, North Carolina
  • OS: OS X Mountain Lion 10.8.5
  • Phone: iPhone 5

Posted 02 February 2013 - 02:03

You've listed 2 WP plugins that do it but don't position it correctly, I've linked you to the OFFICIAL PHP guide for how images are manipulated in PHP, if you had any clue about PHP you'd be able to read it and notice that you need to alter a few lines in the existing plugins to get what you want, it is NOT HARD, in fact it's VERY basic PHP-GD, the functions to search for are all listed on the page.
Don't say it's because it's wordpress, you can't do it when a simple solution exists. Try the simple solution instead of repeatedly bashing it and you might learn some PHP in the process.


The process is to add the watermark UNDER the image which creates a new size. Those plugins are just offset alignments. There are people who learned PHP through WordPress and the help of of programmers. Sometimes the book is just not quick enough.

#23 OP Mr.XXIV

Mr.XXIV

    Shine bright like Iron Man.

  • Tech Issues Solved: 1
  • Joined: 30-April 11
  • Location: Durham, North Carolina
  • OS: OS X Mountain Lion 10.8.5
  • Phone: iPhone 5

Posted 02 February 2013 - 16:38

You've listed 2 WP plugins that do it but don't position it correctly, I've linked you to the OFFICIAL PHP guide for how images are manipulated in PHP, if you had any clue about PHP you'd be able to read it and notice that you need to alter a few lines in the existing plugins to get what you want, it is NOT HARD, in fact it's VERY basic PHP-GD, the functions to search for are all listed on the page.
Don't say it's because it's wordpress, you can't do it when a simple solution exists. Try the simple solution instead of repeatedly bashing it and you might learn some PHP in the process.

EDIT: In fact, the http://wordpress.org...rmark-reloaded/ plugin which was mentioned previously says it can already do this;
'Watermark outside picture'.


You do realize that's a "To-Do" list, right?

#24 n_K

n_K

    Neowinian Senior

  • Tech Issues Solved: 3
  • Joined: 19-March 06
  • Location: here.
  • OS: FreeDOS
  • Phone: Nokia 3315

Posted 02 February 2013 - 19:06

You do realize that's a "To-Do" list, right?

*slaps self*
Apologies for not reading right.

#25 OP Mr.XXIV

Mr.XXIV

    Shine bright like Iron Man.

  • Tech Issues Solved: 1
  • Joined: 30-April 11
  • Location: Durham, North Carolina
  • OS: OS X Mountain Lion 10.8.5
  • Phone: iPhone 5

Posted 03 February 2013 - 15:55

Hm...what is the media_handle_upload() function in submit_user_images.php on line 171? I can't seem to find it and I believe that is where the image data is actually being handled.

*slaps self*
Apologies for not reading right.


So I revised the upload function so that it will directly post to the main taxonomies, additionally making them only pending so I can decide whether it's good or not. it utilizes the media function just like Watermark reloaded, so I think the upload & merge function will come pretty handy. :)

Attached Files





Click here to login or here to register to remove this ad, it's free!