简体   繁体   English

带有php和ajax请求的自定义表单

[英]Custom form with php and ajax request

I use a custom php image library which generate images and I need a script to update the functions when I select a color, font, size etc. 我使用自定义的PHP图像库来生成图像,当我选择颜色,字体,大小等时,我需要一个脚本来更新功能。

here i have all function taht i need to implement, but i need only a demo http://dev.template-tuners.com/makeaplate/ 在这里,我具有需要实现的所有功能,但我只需要演示http://dev.template-tuners.com/makeaplate/

this is the code for my image 这是我的图像的代码

$imageLibObj = new imageLib('plate-yellow.png');
$imageLibObj -> addText(
    'YOUR REG', 
    $position = '85x21', 
    $padding = 0, 
    $fontColor = '#000', 
    $fontSize = 110, 
    $angle = 0, 
    $font = 'image_lib/fonts/UKNumberPlate.ttf'
);
$imageLibObj -> addWatermark('black-border.png', 'tr', 5, 0);
$imageLibObj -> addWatermark('blue-background-badge.png', '6 x 5', 0, 0);
$imageLibObj -> addWatermark('euro-gb.png', '14 x 24', 0, 0);
$imageLibObj -> addText('YOUR SLOGAN HERE', 
    $position = 'b', 
    $padding = 3, 
    $fontColor = '#ff0000', 
    $fontSize = 10, 
    $angle = 0
);
$imageLibObj -> saveImage('plate-demo.png', 100);
$imageLibObj->reset();

Any help please? 有什么帮助吗?

You can use a color picker and post it to your script. 您可以使用颜色选择器并将其发布到脚本中。 JQuery has a color picker plugin ( http://www.eyecon.ro/colorpicker/ ) and there are many others... jQuery有一个颜色选择器插件( http://www.eyecon.ro/colorpicker/ ),还有很多其他...

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM