הרשם | שאלות ותשובות | רשימת חברים | לוח שנה | הודעות מהיום | חיפוש |
|
|
כלים לאשכול | תצורת הצגה |
17-06-06, 10:13 | # 1 |
Fatal Error
|
יצירת רקע שקוף ב PHP
אהלן
יש לי תמונה של עיגול נניח שמקיף אותו ריבוע. אני מעוניין שהעיגול יצבע בצבע שמקבל העמוד כפרמטר (page.php?color=000000) והריבוע יהיה שקוף. איך עושים את זה?
__________________
eLad |
17-06-06, 11:04 | # 2 |
הוסטסניון
|
אתה בודק בעזרת הGET מה הערך של COLOR ואז מדפיס את זה....
PHP קוד:
|
17-06-06, 11:07 | # 3 | |
Fatal Error
|
ציטוט:
__________________
eLad |
|
17-06-06, 11:11 | # 4 |
משתמש - היכל התהילה
|
קוד:
<?php // example4.php // set the HTTP header type to PNG header("Content-type: image/png"); // set the width and height of the new image in pixels $width = 350; $height = 360; // create a pointer to a new true colour image $im = ImageCreateTrueColor($width, $height); // switch on image antialising if it is available ImageAntiAlias($im, true); // sets background to white $white = ImageColorAllocate($im, 255, 255, 255); ImageFillToBorder($im, 0, 0, $white, $white); // define black and blue colours $black = ImageColorAllocate($im, 0, 0, 0); $blue = ImageColorAllocate($im, 0, 0, 255); // draw an empty circle ImageEllipse($im, 180, 100, 100, 100, $black); // draw a filled ellipse ImageFilledEllipse($im, 180, 220, 150, 50, $blue); // send the new PNG image to the browser ImagePNG($im); // destroy the reference pointer to the image in memory to free up resources ImageDestroy($im); ?> View Example 4 To draw a circle or an ellipse, we use the same ImageEllipse function. The parameters provided to this function are: image resource, center x, center y, width, height, colour. As you can see from the above example, all you need to do to draw a circle rather than an ellipse is to set the width and height to the same value. http://www.design-ireland.net/index....imagery-15.php |
17-06-06, 11:28 | # 5 |
הוסטסניון
|
לא ידעתי שהוא רצה את זה בGD...
|
17-06-06, 14:52 | # 6 |
Fatal Error
|
תודה mlnn אך לא זו הייתה הכוונה שלי.
נשאל בצורה אחרת - איך יוצרים רקע שקוף בעזרת GD??
__________________
eLad |
17-06-06, 14:57 | # 7 |
הוסטסניון
|
אהההההם תנסה לשים תמונה שהיא עם רקע שקוף...תמונה GIF (כמו שהפוטושופ יוצר)
|
17-06-06, 16:16 | # 8 | |
Fatal Error
|
ציטוט:
__________________
eLad |
|
17-06-06, 16:18 | # 9 |
הוסטסניון
|
אז מה אתה צריך? אני לא מבין אותך! אתה אומר איך לעשות שקוף...אני נותן לך שקוף...מה עוד אתה רוצה?
|
17-06-06, 16:36 | # 10 |
кто ты?
|
תנסה, תבדוק שזה עובד ותביא לו.
אל תזרוק שטויות לאוויר |
חברים פעילים הצופים באשכול זה: 1 (0 חברים ו- 1 אורחים) | |
|
|