|
Author | Topic: Smiley Gallery (Read 1,535 times) |
Wrighty
![[image]](http://sz-ex.com/v1/wfactor.png) Thinks he deserves a custom title, lol. member is offline
![[avatar]](http://av.wservices.co.uk/av.png)
*Has a custom title*
Joined: Oct 2007 Gender: Male  Posts: 1,400 Location: UK Karma: 34 |  | Smiley Gallery « Thread Started on Jul 8, 2008, 7:51pm » | |
This code will replace the smilies list with the text: 'Smiley Gallery', which when clicked will show a pop-up similar to SZ quick reply one. That shows the smilies.
Note: to use extra smilies with this code, make sure you use the part at the top of the code, which is in red. This CAN be omitted if you don't want to use extra smilies.
<script> /*Smiley Gallery Extra Smilies*/ var w_e_smile = [ ["http://s2.images.proboards.com/laugh.gif", ":lol:"], ["http://s2.images.proboards.com/laugh.gif", ":lol:"], ["http://s2.images.proboards.com/laugh.gif", ":lol:"]//<<< NO COMMA ON THIS LINE! ]; </script>
<script> /*Smiley Gallery Created By Wrighty Do not: rip, repost or claim*/
var s = { d: document.getElementsByTagName('td'), win: function(){ var g = window.open("","Smilies", "width=325,height=10,scrollbars=yes").document.body.appendChild( this.x.cloneNode(true) ); }, link: '<a href = "javascript: s.win();">Smiley Gallery</a>', x: document.createDocumentFragment(), s: '', init: function(){ if(document.postForm){ this.build(); } }, build: function(){ for(a = 0; a < this.d.length; a++){ if(/Smilies:/.test(this.d[a].innerHTML) && /windowbg2/.test(this.d[a].className)){ this.d[a+1].innerHTML = this.d[a+1].innerHTML.replace(/add/g, 'window.opener.add'); this.s = this.d[a+1].firstChild.cloneNode(true); this.d[a+1].firstChild.innerHTML = this.link; break; } } this.x.appendChild(document.createElement('br')); var d = document.createElement('center'); d.appendChild(this.s); if(typeof w_e_smile != 'undefined'){ for(a = 0; a < w_e_smile.length; a++){ var x = document.createElement('a'); var y = document.createElement('img'); y.src = w_e_smile[a][0]; y.border = '0'; x.appendChild(y); x.href = 'javascript:window.opener.add(" ' + w_e_smile[a][1] + '")'; d.appendChild(x); d.appendChild(document.createTextNode(' ')); } } d.appendChild(document.createElement('br')); var ar = document.createElement('a'); ar.href = 'javascript: window.close();'; ar.appendChild(document.createTextNode('Close Window')); d.appendChild(ar); this.x.appendChild(d); } }; s.init(); </script>
Global Footer
|
![[image]](http://wimg.mp/nfA.png) |
|
superkid Senior Member
    [p:18] member is offline
=]
Joined: Jun 2008 Gender: Male  Posts: 265 Karma: 0 |  | Re: Smiley Gallery « Reply #1 on Jul 18, 2008, 3:52pm » | |
I don't think this is compactable with the extra smileys code...
|
![[image]](http://wimg.co.uk/cDioOz.jpg) |
|
Wrighty
![[image]](http://sz-ex.com/v1/wfactor.png) Thinks he deserves a custom title, lol. member is offline
![[avatar]](http://av.wservices.co.uk/av.png)
*Has a custom title*
Joined: Oct 2007 Gender: Male  Posts: 1,400 Location: UK Karma: 34 |  | Re: Smiley Gallery « Reply #2 on Jul 18, 2008, 5:15pm » | |
Could you link me to the extra smilies code that you are using please?
|
![[image]](http://wimg.mp/nfA.png) |
|
superkid Senior Member
    [p:18] member is offline
=]
Joined: Jun 2008 Gender: Male  Posts: 265 Karma: 0 | |
Wrighty
![[image]](http://sz-ex.com/v1/wfactor.png) Thinks he deserves a custom title, lol. member is offline
![[avatar]](http://av.wservices.co.uk/av.png)
*Has a custom title*
Joined: Oct 2007 Gender: Male  Posts: 1,400 Location: UK Karma: 34 |  | Re: Smiley Gallery « Reply #4 on Jul 18, 2008, 7:16pm » | |
Extra smilies is now supported, re-read the first post!
|
![[image]](http://wimg.mp/nfA.png) |
|
superkid Senior Member
    [p:18] member is offline
=]
Joined: Jun 2008 Gender: Male  Posts: 265 Karma: 0 |  | Re: Smiley Gallery « Reply #5 on Aug 8, 2008, 9:36pm » | |
Oh, and is there a need for the censored word list?
|
![[image]](http://wimg.co.uk/cDioOz.jpg) |
|
Wrighty
![[image]](http://sz-ex.com/v1/wfactor.png) Thinks he deserves a custom title, lol. member is offline
![[avatar]](http://av.wservices.co.uk/av.png)
*Has a custom title*
Joined: Oct 2007 Gender: Male  Posts: 1,400 Location: UK Karma: 34 |  | Re: Smiley Gallery « Reply #6 on Aug 8, 2008, 11:19pm » | |
Yes, use the censored words.
|
![[image]](http://wimg.mp/nfA.png) |
|
Koivu New Member
 member is offline
Joined: Dec 2008 Gender: Male  Posts: 3 Karma: 0 |  | Re: Smiley Gallery « Reply #7 on Dec 9, 2008, 11:35pm » | |
I like the Sound of this code but i can't get it to work on my forum .. Any chance of getting some help ??
| |
|
James
![[image]](http://sz-ex.com/v1/wfactor.png) member is offline
I used to be rich >.<'
Joined: Jun 2008 Gender: Male  Posts: 757 Location: UK Karma: 23 | |
Koivu New Member
 member is offline
Joined: Dec 2008 Gender: Male  Posts: 3 Karma: 0 | |
Koivu New Member
 member is offline
Joined: Dec 2008 Gender: Male  Posts: 3 Karma: 0 |  | Re: Smiley Gallery « Reply #10 on Dec 11, 2008, 7:23pm » | |
* Bump *
| |
|
Chris [Away] Head Coder
      Click Click Boom member is offline
Joined: Nov 2006 Gender: Male  Posts: 15,550 Location: Nebraska Karma: 289 |  | Re: Smiley Gallery « Reply #11 on Dec 19, 2008, 7:18pm » | |
The only code conflict I can possible see is this one:
/* "What Are You Listening To" In Posts v1.1
How is the code not working, specifically?
|
![[image]](http://sz-ex.com/misc/sigs/staff/style4/admin_chris.png)
![[image]](http://apocalypse.hstr.me/StudioZero/projectapocalypsechris.png) |
|
eveready Dedicated Member
   [p:10] member is offline
Joined: Aug 2007 Posts: 136 Karma: 0 |  | Re: Smiley Gallery « Reply #12 on Nov 7, 2009, 7:06am » | |
I copied this code as is in a board with no other codes. The extra smileys are not showing up.
http://eveready11.proboards.com
Also, if you close the popup, and then try to reopen it, the popup box is empty. And if the box is already open, but out of view and behind the window, and you click on 'smiley gallery', the same smileys will be duplicated in the popup. I wonder if these issues could be fixed as well.
Thanks.
| |
|
Chris [Away] Head Coder
      Click Click Boom member is offline
Joined: Nov 2006 Gender: Male  Posts: 15,550 Location: Nebraska Karma: 289 |  | Re: Smiley Gallery « Reply #13 on Nov 9, 2009, 7:25pm » | |
Nov 7, 2009, 7:06am, eveready wrote:I copied this code as is in a board with no other codes. The extra smileys are not showing up.
http://eveready11.proboards.com
Also, if you close the popup, and then try to reopen it, the popup box is empty. And if the box is already open, but out of view and behind the window, and you click on 'smiley gallery', the same smileys will be duplicated in the popup. I wonder if these issues could be fixed as well.
Thanks. |
|
I've fixed the bug regarding the smilies not reappearing if you close and reopen. I can not reproduce either of the other bugs however. What browser are you using?
|
![[image]](http://sz-ex.com/misc/sigs/staff/style4/admin_chris.png)
![[image]](http://apocalypse.hstr.me/StudioZero/projectapocalypsechris.png) |
|
eveready Dedicated Member
   [p:10] member is offline
Joined: Aug 2007 Posts: 136 Karma: 0 |  | Re: Smiley Gallery « Reply #14 on Nov 10, 2009, 2:08am » | |
Thanks.
Yeah, it's a browser issue. Not sure why I didn't think of that, but I've been using Google Chrome and haven't had any similar issues.
| |
|
|