Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> [css] wyzwanie
AndyPSV
post
Post #1





Grupa: Zarejestrowani
Postów: 393
Pomógł: 5
Dołączył: 6.02.2003
Skąd: The.Luciferian.Doctrine.p
df

Ostrzeżenie: (30%)
XX---


kto potrafi zmontowac cos takiego:
http://img242.imageshack.us/img242/6948/ocochodzifw4.gif
+ aby dopasowywal automatycznie dlugosc, wysokosc okna do tekstu (jest to chyba w css wykonywalne, nie? chyba, ze sie myle)

tutaj grafiki: http://www.sendspace.pl/file/BhO23GMi/

Jak dla mnie czysta patologia. Szacunek wielki kto potrafi to namalowac.
Go to the top of the page
+Quote Post
 
Start new topic
Odpowiedzi (1 - 7)
Pilsener
post
Post #2





Grupa: Zarejestrowani
Postów: 1 590
Pomógł: 185
Dołączył: 19.04.2006
Skąd: Gdańsk

Ostrzeżenie: (0%)
-----


Sprecyzuj, co chcesz osiągnąć, bo nic z tego nie rozumiem.
Go to the top of the page
+Quote Post
vokiel
post
Post #3





Grupa: Zarejestrowani
Postów: 2 592
Pomógł: 445
Dołączył: 12.03.2007

Ostrzeżenie: (0%)
-----


Może gotowiec? tooltip_e
Go to the top of the page
+Quote Post
revyag
post
Post #4





Grupa: Przyjaciele php.pl
Postów: 2 258
Pomógł: 16
Dołączył: 21.09.2004
Skąd: Kielce

Ostrzeżenie: (0%)
-----


Tak trudno jest się troszkę wysilić i poszukać ? Całe 20 sekund szukałem.
http://php-ajax-code.blogspot.com/2007/07/...nd-balloon.html
Go to the top of the page
+Quote Post
AndyPSV
post
Post #5





Grupa: Zarejestrowani
Postów: 393
Pomógł: 5
Dołączył: 6.02.2003
Skąd: The.Luciferian.Doctrine.p
df

Ostrzeżenie: (30%)
XX---


@vokiel: problem w tym, ze ten "gotowiec" zajmuje nieco ponad 45kb...
@Pilsener: chce narysowac w htmlu takie cos jak na rysunku.

probowalem cos takiego
  1. <style type="text/css">
  2. <!--
  3. body{margin:5px;font-family:Tahoma,Verdana,Arial;font-size:11px;color:#000;}
  4. div,dl,dt,dd,ul,ol,li,h1,h2,h3,h4,h5,h6,pre,form,fieldset,input,p,blockquote,th,
  5. d{margin:0;padding:0;}table{border-collapse:collapse;border-spacing:0;}fieldset,img{border:0;}address,caption,cite,code,dfn,em,strong,th,var
    {font-style:normal;font-weight:normal;}ol,ul {list-style:none;}caption,th {text-align:left;}h1,h2,h3,h4,h5,h6{font-size:100%;}q:before,q:after{content:'';}
  6. -->
  7. <tr>
  8. <td><img src=lt.gif /></td>
  9. <td><img src=t.gif /></td>
  10. <td><img src=rt.gif /></td>
  11. </tr>
  12.  
  13. <tr>
  14. <td><img src=t.gif /></td>
  15.  
  16. <td style="background-color: #fffbcc;">Serwis Wikileaks.org ujawnił, że władze Stanów Zjednoczonych i
  17. pozostałych krajów grupy G8 intensywnie pracujš nad wielostronnym
  18. porozumieniem handlowym, zwanym ACTA, które całkowicie zdelegalizuje
  19. nawet niedochodowš wymianę zastrzeżonej prawem autorskim informacji. Nie
  20. chodzi tu tylko o tak banalnš sprawę, jak delegalizacja
  21. </td>
  22. <td><img src=t.gif /></td>
  23. </tr>
  24. <!--
  25. <tr>position:relative;top:1px;z-index:1;displayasd:none;"
  26. <td width=1 height=6 style="position:relative;padding:0px;margin:0px;overflow:hidden;background-image:url('t.gif');">&nbsp;</td>
  27. <td width=1 height=6 style="background-color:#e2e2e2;">SDSDSNDNSJKDNKSJDNKSDNJKSDNKSD</td>
  28. <td width=1 height=6 style="position:relative;padding:0px;margin:0px;overflow:hidden;background-image:url('t.gif');">&nbsp;</td>
  29. </tr>
  30. -->


  1. Jest na to taki kod:
  2. Kod:
  3. if(tt_aV[BALLOONIMGPATH] == config.BalloonImgPath)
  4. aImg = balloon.aDefImg;
  5. // ...or load images from different directory
  6. else
  7. aImg = Balloon_CacheImgs(tt_aV[BALLOONIMGPATH]);
  8. sCssCrn = ' style="position:relative;width:' + tt_aV[BALLOONEDGESIZE] + 'px;padding:0px;margin:0px;overflow:hidden;line-height:0px;';
  9. sVaT = 'vertical-align:top;" valign="top"';
  10. sVaB = 'vertical-align:bottom;" valign="bottom"';
  11. sCssImg = 'padding:0px;margin:0px;border:0px;';
  12. sImgZ = '" style="' + sCssImg + '" />';
  13.  
  14. tt_sContent = '<table border="0" cellpadding="0" cellspacing="0" style="width:auto;padding:0px;margin:0px;left:0px;top:0px;"><tr>'
  15. // Left-top corner
  16. + '<td' + sCssCrn + sVaB + '>'
  17. + '<img src="' + aImg[1].src + '" width="' + tt_aV[BALLOONEDGESIZE] + '" height="' + tt_aV[BALLOONEDGESIZE] + sImgZ
  18. + '</td>'
  19. // Top border
  20. + '<td valign="bottom" style="position:relative;padding:0px;margin:0px;overflow:hidden;">'
  21. + '<img id="bALlOOnT" style="position:relative;top:1px;z-index:1;display:none;' + sCssImg + '" src="' + aImg[9].src + '" width="' + tt_aV[BALLOONSTEMWIDTH] + '" height="' + tt_aV[BALLOONSTEMHEIGHT] + '" />'
  22. + '<div style="position:relative;z-index:0;padding:0px;margin:0px;overflow:hidden;width:auto;height:' + tt_aV[BALLOONEDGESIZE] + 'px;background-image:url(' + aImg[2].src + ');">'
  23. + '</div>'
  24. + '</td>'
  25. // Right-top corner
  26. + '<td' + sCssCrn + sVaB + '>'
  27. + '<img src="' + aImg[3].src + '" width="' + tt_aV[BALLOONEDGESIZE] + '" height="' + tt_aV[BALLOONEDGESIZE] + sImgZ
  28. + '</td>'
  29. + '</tr><tr>'
  30. // Left border
  31. + '<td style="position:relative;padding:0px;margin:0px;width:' + tt_aV[BALLOONEDGESIZE] + 'px;overflow:hidden;background-image:url(' + aImg[8].src + ');">'
  32. // Redundant image for bugous old Geckos that won't auto-expand TD height to 100%
  33. + '<img width="' + tt_aV[BALLOONEDGESIZE] + '" height="100%" src="' + aImg[8].src + sImgZ
  34. + '</td>'
  35. // Content
  36. + '<td id="bALlO0nBdY" style="position:relative;line-height:normal;'
  37. + ';background-image:url(' + aImg[0].src + ')'
  38. + ';color:' + tt_aV[FONTCOLOR]
  39. + ';font-family:' + tt_aV[FONTFACE]
  40. + ';font-size:' + tt_aV[FONTSIZE]
  41. + ';font-weight:' + tt_aV[FONTWEIGHT]
  42. + ';text-align:' + tt_aV[TEXTALIGN]
  43. + ';padding:' + balloon.padding + 'px'
  44. + ';width:' + ((balloon.width > 0) ? (balloon.width + 'px') : 'auto')
  45. + ';">' + tt_sContent + '</td>'
  46. // Right border
  47. + '<td style="position:relative;padding:0px;margin:0px;width:' + tt_aV[BALLOONEDGESIZE] + 'px;overflow:hidden;background-image:url(' + aImg[4].src + ');">'
  48. // Image redundancy for bugous old Geckos that won't auto-expand TD height to 100%
  49. + '<img width="' + tt_aV[BALLOONEDGESIZE] + '" height="100%" src="' + aImg[4].src + sImgZ
  50. + '</td>'
  51. + '</tr><tr>'
  52. // Left-bottom corner
  53. + '<td' + sCssCrn + sVaT + '>'
  54. + '<img src="' + aImg[7].src + '" width="' + tt_aV[BALLOONEDGESIZE] + '" height="' + tt_aV[BALLOONEDGESIZE] + sImgZ
  55. + '</td>'
  56. // Bottom border
  57. + '<td valign="top" style="position:relative;padding:0px;margin:0px;overflow:hidden;">'
  58. + '<div style="position:relative;left:0px;top:0px;padding:0px;margin:0px;overflow:hidden;w
    idth:auto;height:' + tt_aV[BALLOONEDGESIZE] + 'px;background-image:url(' + aImg[6].src + ');"
    ></div>
    '
  59. + '<img id="bALlOOnB" style="position:relative;top:-1px;left:2px;z-index:1;display:none;' + sCssImg + '" src="' + aImg[10].src + '" width="' + tt_aV[BALLOONSTEMWIDTH] + '" height="' + tt_aV[BALLOONSTEMHEIGHT] + '" />'
  60. + '</td>'
  61. // Right-bottom corner
  62. + '<td' + sCssCrn + sVaT + '>'
  63. + '<img src="' + aImg[5].src + '" width="' + tt_aV[BALLOONEDGESIZE] + '" height="' + tt_aV[BALLOONEDGESIZE] + sImgZ
  64. + '</td>'
  65. + '</tr></table>';


ale po podmienieniu wszystkiego kod w ogole nie przypomina niczego ;/
moglbys to mi naszkicowac? gdybym potrafil to bym nie pisal postu na forum...
Go to the top of the page
+Quote Post
Shili
post
Post #6





Grupa: Zarejestrowani
Postów: 1 085
Pomógł: 231
Dołączył: 12.05.2008

Ostrzeżenie: (0%)
-----


Kod html jest bardzo prosty, nie chce mi się pisać pod Twój, bo nie do końca chce mi sie go analizować, ale mniej więcej pokażę jak może to wyglądać.

  1. <script type="text/javascript">
  2. function pokazBalonik(id) {
  3. if(document.getElementById(id).style.display = "none")
  4. document.getElementById(id).style.display = "block";
  5. else
  6. document.getElementById(id).style.display = "none";
  7. }
  8. <p onclick="pokazBalonik('pokazBalonik1');">Tutaj tekst nad którym pokaże się balonik</p>
  9. <div style="display: none;" id="pokazBalonik1">Tutaj kod balonika</div>

Pozycja i style to sprawa drugorzędna myślę. Jeśli dobrze ostylujesz i podobierasz tła powstanie balonik - wystarczy użyć przezroczystości w gifach, a będzie przezroczysty. Do uzyskania balonika o zmiennej szerokości i wysokości poczytaj o zaokrąglonych rogach, a na sam dół daj tło z tym kierunkowym czymś. Ten balonik jest na kliknięcie, ale podobnie można zrobić na inne akcje.

Oczywiście to tylko zarys potrzebnego skryptu, coś w stylu naprowadzenia bardziej.

Ten post edytował Shili 29.05.2008, 14:21:41
Go to the top of the page
+Quote Post
pest
post
Post #7





Grupa: Zarejestrowani
Postów: 78
Pomógł: 15
Dołączył: 10.12.2007
Skąd: Lublin

Ostrzeżenie: (0%)
-----


Bierz gotowy skrypt i go zminimalizuj - są do tego narzędzia w sieci (IMG:http://forum.php.pl/style_emoticons/default/winksmiley.jpg)

Odpada dużo roboty i zniechęcenia (IMG:http://forum.php.pl/style_emoticons/default/winksmiley.jpg)
Go to the top of the page
+Quote Post
AndyPSV
post
Post #8





Grupa: Zarejestrowani
Postów: 393
Pomógł: 5
Dołączył: 6.02.2003
Skąd: The.Luciferian.Doctrine.p
df

Ostrzeżenie: (30%)
XX---


chodzi mi wlasnie o to, ze SKRYPT MAM tylko mam spory problem z NARYSOWANIEM tego co sie wyswietla; czy ktos moglby wiec mi pomoc ? chociaz do polowy pokazac czy cos
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
2 Użytkowników czyta ten temat (2 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Aktualny czas: 23.08.2025 - 03:58