if i open the .php page in my webbrowser, it will download it and i can't see a image. If i make a link to the page it also downloads it. can someone help me?
@idiotrun1997 How could it not be useful to generate an image with PHP. It means you could generate signatures for your users to use on your website as well as other people's websites (forums), that kind of thing.
i love this tutorials realy i didn't know that you can make pictures with PHP THATS AMAIZING
*good thing about it is that you can make some text that the user cannot copy (you forse him (or her) to monually type something again ANYWAY GREAT TUTORIALS
@phpacademy Can you set the background to an image instead of solid color? Say I wanted to create a default avatar for the users that was personalized with their username but I wanted an image with text on it not just a boring solid color background.
I got a question. Why is the background black instead of white, since you apply the same method in background and foreground variable, and the foreground comes last. Why foreground didn't overlay background ?
really good tutorial.. but i have got one problem.. after doing this if i write anything in my html file's body nothing appears on the screen accept for the image i created.
@plutonimvamsi there where around 32 0r 33 characters to be displayed,and we show it fit perfectly in 300 width.....so 300/32=9.3.so that 9.3 is approx. width of each character...well that's my opinion it could be wrong:)
I made a program specifically for RGB, Hex, and binary translating. It also comes with a calculator incase you need to do any calculations. PM me if you're interested in it. The RGB part converts a color into hex and in our number system too. You basically get a color panel and you can choose a color. Then my program does the rest of the work. This comment was made when I hit 2:43 of the vid by the way, when you started mentioning RGB.
Really good tutorial, got the point across (even though I knew how to do this already myself).
One small problem however is that you can make this more accurate by using a function which comes with the GD library called imagefontwidth(font) which takes a font as a parameter (for example: 5) and returns the width of a single character in that font.
I´m not allowed to edit header info if I call this php code from inside another html document. Due to an output is allready sent. What can I do to solve this?
Thank Alex. I have to rate this video 5/5. First I thought yet another long tutorial but well it was so interesting all the way and to the point and very brief.
I have one question. Looking at this video, I realized how they make those images on the fly to avoid spam. Do they make it this way. I just wanted to hear from you about this. They probably distort the image after they create it to make it hard to read. A reply would be appreciated :)
@omanoman98 9.3 is the width of each character, e.g "a" "b" "c" etc... and basically the strlen function counts how many characters there are in the message variable, and then the length variable multiplies the amount of characters by the width of the charaters, and gives you a dynamic width the picture should be :)
if i open the .php page in my webbrowser, it will download it and i can't see a image. If i make a link to the page it also downloads it. can someone help me?
fruitman89 5 days ago
Wonderful Tutorial
zakamid 1 month ago
some errors when try to create unicode text image ! Descript the solution about ! Ths
tinhnguyenbn 2 months ago
how do i change the size of the image text?
goofy3256 2 months ago
that's awesome
TrojanSpike1 4 months ago in playlist General Tutorials
How would it be useful to generate an image with PHP?
idiotrun1997 6 months ago
@idiotrun1997 How could it not be useful to generate an image with PHP. It means you could generate signatures for your users to use on your website as well as other people's websites (forums), that kind of thing.
Hug0101 6 months ago
Just a question for the background, can u use an photoshopped image? as background with text on it?
MrRobinatorzzz 6 months ago
@MrRobinatorzzz You can use any image you want as the background image.
Hug0101 6 months ago
@Hug0101 Already found it , but it's diffucult for some exact positions :p
MrRobinatorzzz 6 months ago
@MrRobinatorzzz Could you send me a link via Youtube Messaging? :)
Hug0101 6 months ago
i love this tutorials realy i didn't know that you can make pictures with PHP THATS AMAIZING
*good thing about it is that you can make some text that the user cannot copy (you forse him (or her) to monually type something again ANYWAY GREAT TUTORIALS
vbtutpro 6 months ago
@phpacademy Can you set the background to an image instead of solid color? Say I wanted to create a default avatar for the users that was personalized with their username but I wanted an image with text on it not just a boring solid color background.
jimjimmy1995 7 months ago in playlist General Tutorials
I got a question. Why is the background black instead of white, since you apply the same method in background and foreground variable, and the foreground comes last. Why foreground didn't overlay background ?
paulver00 7 months ago
@paulver00 Because you wrote the value of the function to one variable and then a different variable. The first variable is not overwritten.
jimjimmy1995 7 months ago in playlist General Tutorials
This has been flagged as spam show
havij works better :) mediafire . com/?d4d9ackbidf77go
sneakylight 7 months ago
that's pretty awesome :D
DeDean16 8 months ago
i love you alex - Acceptable67
Acceptable76 8 months ago
can we save this image directly and access that using<img src=''????? please reply...
linuguddu 10 months ago
really good tutorial.. but i have got one problem.. after doing this if i write anything in my html file's body nothing appears on the screen accept for the image i created.
linuguddu 10 months ago
@linuguddu : nothing appears in my php file body.
linuguddu 10 months ago
Ok. This…
Looks EPIC!
I'm on my iPod, but next time I get on the computer, I'm totally testing this! Adding to my website and changing my profile puc!
Thanks man!
JelvinJS7 11 months ago
Cool Video Thanks! :D
Dolter9 1 year ago
hey alex , i'm new to php so forgive me if my question stupid or anything.....
i ran that code in opera 10.53 ,instead getting image at upper left corner i am getting the image at the center...why?
by the way,great tuts:)
justheretowatch2010 1 year ago
please tell how you used 9.3 ?
plutonimvamsi 1 year ago
@plutonimvamsi there where around 32 0r 33 characters to be displayed,and we show it fit perfectly in 300 width.....so 300/32=9.3.so that 9.3 is approx. width of each character...well that's my opinion it could be wrong:)
justheretowatch2010 1 year ago
I don't understand how the background color is set. I see how $background is declared, but it's not being used anywhere like $foreground is. Thx!
tropicallanterns 1 year ago
Thanks a Lot Alex, That Was One Wicked Tutorial... Keep Up The Great Work... and if you could please provide a bit more example on the GD Library.
abdulask 1 year ago
Nice video... But when I write this code and try to start it it I see this :
Fatal error: Call to undefined function: imagecreate() in c:\apache\htdocs\generator.php on line 20
Do you know what to do plls?
alukiMreteP 1 year ago
Hey Alex, is there a way to set a chroma key, as I need to remove rgb(255,125,25) from my image
VinnyBenson 1 year ago
Try OB_START();
brokenbylaw2 1 year ago
I made a program specifically for RGB, Hex, and binary translating. It also comes with a calculator incase you need to do any calculations. PM me if you're interested in it. The RGB part converts a color into hex and in our number system too. You basically get a color panel and you can choose a color. Then my program does the rest of the work. This comment was made when I hit 2:43 of the vid by the way, when you started mentioning RGB.
crazynoob11 1 year ago
move the session_start(); to the top of the script
H3dQ 2 years ago
cool it works, but how do you add other text to the page?
shanetalbert 2 years ago
You have to make a form and to use the viariable get to add some text or directly to the script
thierrydel1 2 years ago
Really good tutorial, got the point across (even though I knew how to do this already myself).
One small problem however is that you can make this more accurate by using a function which comes with the GD library called imagefontwidth(font) which takes a font as a parameter (for example: 5) and returns the width of a single character in that font.
So the $length variable can be set like so:
$font_size = 5;
$length = strlen($message) * imagefontwidth($font_size);
Good video.
SwiftNinjaChaos 2 years ago
how can i make make a character maker?
evermanito 2 years ago
can you change the font?
onlinecmd34 2 years ago
I´m not allowed to edit header info if I call this php code from inside another html document. Due to an output is allready sent. What can I do to solve this?
vingard 2 years ago
Result is: The image is not showed. The code is ok here if I just run this php alone.
vingard 2 years ago
Thank Alex. I have to rate this video 5/5. First I thought yet another long tutorial but well it was so interesting all the way and to the point and very brief.
I have one question. Looking at this video, I realized how they make those images on the fly to avoid spam. Do they make it this way. I just wanted to hear from you about this. They probably distort the image after they create it to make it hard to read. A reply would be appreciated :)
Again thanks for the wonderful tutorial.
bot06 2 years ago
to put a custom background (not solid one), what do I have to do ?
Thanks,
Shay
By the way awesome tut!
ShashooX 2 years ago
Comment removed
ShashooX 2 years ago
Hi Alex...
Thanks for this wonderful tutorial!
Can I just ask to show me how exactly you arrived at 9.3, please?
Kindly walk me through the math there!
omanoman98 2 years ago
It's purely experimental :)
phpacademy 2 years ago
meaning what though? sorry Alex- but I am still confused?
omanoman98 2 years ago
I just changed the figure until it looked right
phpacademy 2 years ago
Aha...I see!Thanks for your quick reply!
omanoman98 2 years ago
@omanoman98 9.3 is the width of each character, e.g "a" "b" "c" etc... and basically the strlen function counts how many characters there are in the message variable, and then the length variable multiplies the amount of characters by the width of the charaters, and gives you a dynamic width the picture should be :)
Hope this helps.
bassatcollege 1 year ago
Comment removed
omanoman98 2 years ago
very crisp & clear explanation!
dmggroups 2 years ago 3
Very very very good tutorial and understoodable,
keep posting new tutorials =]
AxelWai 2 years ago 4
Thanks, i'm always recording so there will definatly be more to come!
phpacademy 2 years ago