+Gabriel™ Posted May 25, 2015 Report Posted May 25, 2015 Buna seara. Sa incept cu inceputul Cum pot adauga iconita in locul textului google - yahoo Ca si aici exemplu: Multumesc de atentia acordata.
+strong Posted May 25, 2015 Report Posted May 25, 2015 pai mergi in ftp public/style_extra/search_engine/Google.png Si pentru yahoo /public/style_extra/search_engine/Yahoo.png +1 — steam
+Gabriel™ Posted May 25, 2015 Author Report Posted May 25, 2015 pai mergi in ftp public/style_extra/search_engine/Google.png Si pentru yahoo /public/style_extra/search_engine/Yahoo.png +1 Am incercat si treaba asta si degeaba
Moderators Solution gadeas Posted May 26, 2015 Moderators Solution Report Posted May 26, 2015 Momentan am sa las solutia mea, nu stiu daca este tutorial sau daca exista ceva hook, dar na, mai simplu imi fac eu singur. Cum arata: Cum se face: In globalTemplate inainte de: </head> Adauga urmatoru cod: <script> jQuery(document).ready(function($) { var element = 'p:not(#mot_body) span.name'; $(element).each(function () { var text = $(this).text(); var isComma = text.slice(-1); var imageGoogle = '<img src="http://www.html5rocks.com/static/images/google_logo_small.png" alt="google" />'; var imageYahoo = '<img src="http://www.wsadirectory.com/images/yahoo.png" alt="Yahoo" />'; var imageBing = '<img src="http://www.wsadirectory.com/images/bing.png" alt="Bing" />'; /* Google */ if (text == 'Google' || text == 'Google,') { $(this).html((isComma == ',') ? imageGoogle + ',' : imageGoogle); } /* Yahoo */ if (text == 'Yahoo' || text == 'Yahoo,') { $(this).html((isComma == ',') ? imageYahoo + ',' : imageYahoo); } /* Bing */ if (text == 'Bing' || text == 'Bing,') { $(this).html((isComma == ',') ? imageBing + ',' : imageBing); } }); }); </script> Schimba imaginile ( doar ce e intre src ) cum crezi ca vrei sa fie la: var imageGoogle = '<img src="http://www.html5rocks.com/static/images/google_logo_small.png" alt="google" />'; var imageYahoo = '<img src="http://www.wsadirectory.com/images/yahoo.png" alt="Yahoo" />'; var imageBing = '<img src="http://www.wsadirectory.com/images/bing.png" alt="Bing" />'; In rest, sint sigur ca se putea face mai scurt prin alta metoda, dar na, macar apar imaginiile si verifica putin daca exista sau nu , dupa. 1 PHP Developer - Not available for freelancing right now Daca ai de gand sa postezi la categoria IPB, nu uita sa citesti regulamentul: Link regulament
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now