PHP - How To Use Photoshop's Multiply With Php Gd?
1. Are there any functions that can make a multiply effect using PHP GD?
2. What is the best way to recolour a one-colour PNG while keeping transparency? I've tried this but savealpha isn't working. 3. How can I implement this ImageMagick code into a non-OOP PHP script and use variables for the image urls? Code: [Select] convert label:Rose label_white.gif composite -compose Multiply -gravity center \ label_white.gif rose: compose_multiply.gifhttp://www.imagemagick.org/Usage/compose/#multiply ImageMagick is my last resort... or the resort before using Flash. 4. Also, when the user chooses an option, how can I make the image update automatically (without refreshing)? The information will be passed via GET. Help, please? Similar TutorialsHeja I have a MySQL database which contains information of members and the current balance of there accounts (eg: $1000) it also shows there current gain (eg: 1.2%) what i have been doing is individually updating each clients percent and balance. What i'm trying to work out is how to add a percent gain for the week and both the percent and balance of the clients are updated according to the submitted gain for example: Client 1 has $1,000 and has a current gain of 1.5% Client 2 has $,2000 and has a current gain of 2.5% I want to update both clients by 1.5% and then both clients be updated like so: Client 1 would now have $1,010.50 and now has a gain of 3.0% Client 2 would now have $2,020.50 and now has a gain of 4.0% I was looking around and could find much information on the internet or exactly has this can be achieved so i started to work on a addition and try atleast add the % however it dont go accordingly, i suppose im very rusty at my php. I started working around something like this: Code: [Select] mysql_select_db('mem') or trigger_error("SQL", E_USER_ERROR); $a1 = mysql_query("SELECT profits FROM account"); $a= $a1; $b=$b1; /* html <input type="text" name="b1" id="b1"> the % i want to update*/ $add=($a+$b); $sql = "UPDATE mem SET balance = balance +'$add'"; if (!mysql_query($sql)) { die('Error: ' . mysql_error()); } This obviously does not work but it could possibly give you a better understanding of maybe what im trying to do here. Any help would be appreciated. Thanks hi there - probably simple but cant find a straight example of this anywhere and i am very newby when it comes to programming. have a php search file that works fine with my mysql database. it use this argument for searching: Code: [Select] $result = mysql_query("SELECT * FROM ppl_tracks WHERE Keywords LIKE '%$_POST[searchkeywords]%' AND Mixed !=false ORDER BY Track");obviously Keywords is the field searched but i want it to look for 'searchkeywords' in another field - 'Description' and while at it - is it possible to enter 2 or more keywords in the submit form (using $POST) that will be searched in the 2 fields and will return a list ordered by relevancy (how many of the keywords searched appear in each record) hope this makes sense to someone Hello I though this code would work Code: [Select] mysql_query("UPDATE cart SET totprice = quantity * price WHERE ID='{$id}'")or die(mysql_error());because this is working fine Code: [Select] mysql_query("UPDATE products SET rating = rating + 1 WHERE ID='{$id}'")or die(mysql_error()); Anything wrong with it, or how should i do it? hi. I am stuck on the dropdown box value calculation. anyone can help me on this problem ? I appreciate it. I have two dropdown boxes on my webpage, and the values that in the dropdown boxes are retrived from the mysql database. dropdown box "A" displays two differnt values, which are "Chassise_Name" and "Chassise_price", and The dropdown box "B" displays the quantity of the item. Dropdown box "A" Dropdown box "B" SuperServer 7036A-T(Black) $90 3 "Superserver 7036A-T(Black)" is retrieved from the Chassis_Name ; "$90" is retrieved from the chassis_Price; "3" is retrieved from the Quantity in other table. Question: how can I take only the price on the Dropdown box "A" multiply the number in the Dropdown box "B"? Here is my code: Code: [Select] echo "<table border='1'>"; echo "<tr><td>"; $result = mysql_query("SELECT Chassis_Name, Chassis_Price FROM Chassis where Chassis_Form_Factor='ATX'") or die(mysql_error()); echo '<select name="Chassis" onChange="change()">'; // keeps getting the next row until there are no more to get while($row = mysql_fetch_array( $result )) { // Print out the contents of each row into a table echo '<option Name="Chassis">',$row['Chassis_Name'],' ',$row['Chassis_Price'],' ','</option>'; } echo '</select>'; echo "</td>"; echo "<td>"; $result= mysql_query("SELECT Number FROM Quantity") or die(mysql_error()); echo '<select name="Quantity" Value="Quantity" onChange="change()" >'; // keeps getting the next row until there are no more to get while($row = mysql_fetch_array( $result)) { // Print out the contents of each row into a table echo '<option Name="Quantity">',$row['Number'],'</option>'; } echo '</select>'; echo "</td></tr>"; echo "</table>"; ?> I have a really confusing question. I dynamically generate arrays, but for the simplicity of the example we can just use two arrays. Code: [Select] Array 1 ( [0] = 1 [1] = 5 ) Array 2 ( [0] = 2 [1] = 6 ) How can I make the arrays multiple based on the same key value? array 1[0] * array 2[0] = 2 array 1[1] * array 2[1] = 30 I then want to sum the total of the multiplication. $total = 2 + 30; I need to do this to calculate covariance for a statistics procedure I am trying to run but I can't wrap my head around how to do the logic. How can i make a clickable input button in photoshop, when i click save for web it's just and image.
<?php shell_exe ("172.18.9.25\photoshop\photoshop.exe"); ?> When I run this from the server computer program opening. But when i tried from a diferent computer it is only downloading the exe file to the client computer. How can I open the application from a diferent computer in the same network. Hi there, Can anybody help me to write php/javascript code which will allow users to open files directly from web browser into desktop application? Here is the specification: I have a photo editing business with many people working in Photoshop. I am currently developing a web based application (joblist) using Javascript and PHP which should allow the photoshop designers to browse and open files/images directly from joblist/web browser into photoshop. The reason I want this instead of browsing folder is that I have a database where I store who worked on which file, when and how long it took. The concept is that, designers will select a file and click on start, as soon as they click on start the original file will open in Photoshop and there will be an entry into database (using PHP). Once they finish the task they will close the file and click on Finish button. My joblist application will be published in a local server and the file will be open on a local network, so when they save the file it will be saved where the source file is located in (local server). The application should work in both PC and Mac. I have already done all other part of the application except file opening directly from browser to desktop application functionality. Anybody can help me to write the code (PHP or Javascript) which can open the file from browser (local server) directly into desktop application e.g. PHotoshop or Illustrator? Thank you very much I look forward to someone's real help! Best regards Mr. Sumon |