Page Index Toggle Pages: 1
Topic Tools
[SVN] Images in Live Preview not displaying (Read 1,922 times)
Jet Li
Legacy Dev Team
Development Team
****
Offline



Posts: 6,588
Location: Hong Kong
Re: [SVN] Images in Live Preview not displaying
Reply #6 - Jun 15th, 2009 at 5:07pm
Post Tools
New yabbc.js in SVN.

Edited:
commited in CVS too. Wink
« Last Edit: Jun 15th, 2009 at 5:10pm by Jet Li »  

PM me for YaBB Installation Service
Back to top
WWWGTalkFacebook  
IP Logged
 
Carsten
Ex Member


Re: [SVN] Images in Live Preview not displaying
Reply #5 - Jun 15th, 2009 at 5:03pm
Post Tools
While playing with this i found a small glitch conserning the 'edit' tags. In yabbc.js replace
Code
Select All
	ubbcstr=ubbcstr.replace(/\[glow\]/ig, "  [glow]");
	ubbcstr=ubbcstr.replace(/\[\/glow\]/ig, "  [/glow]"); 



with
Code
Select All
	ubbcstr=ubbcstr.replace(/\[edit\]/ig, " [edit]");
	ubbcstr=ubbcstr.replace(/\[\/edit\]/ig, " [/edit]"); 




The 'glow' tage are some leftover from one of my old mods - have no idea how the came to be in the yabbc.js distribution  Huh
  
Back to top
 
IP Logged
 
Jet Li
Legacy Dev Team
Development Team
****
Offline



Posts: 6,588
Location: Hong Kong
Re: [SVN] Images in Live Preview not displaying
Reply #4 - Jun 15th, 2009 at 5:01pm
Post Tools
Thnx. Works now.

New yabbc.js in SVN.

Changelog:
- Fix display images in img tag for Live Preview
  

PM me for YaBB Installation Service
Back to top
WWWGTalkFacebook  
IP Logged
 
Carsten
Ex Member


Re: [SVN] Images in Live Preview not displaying
Reply #3 - Jun 15th, 2009 at 4:43pm
Post Tools
Mutters!! Actually the replacement code should be
Code
Select All
	if(autolinkurls != 0) ubbcstr=ubbcstr.replace(/(^|\]|\s+)((http:\/\/|www\.){1,}\S+?\.\S+)/ig, "$1[url]$2[/url]"); 

  Embarrassed
  
Back to top
 
IP Logged
 
Carsten
Ex Member


Re: [SVN] Images in Live Preview not displaying
Reply #2 - Jun 15th, 2009 at 4:30pm
Post Tools
In yabbc.js change
Code
Select All
	if(autolinkurls != 0) ubbcstr=ubbcstr.replace(/((http:\/\/|www\.){1,}\S+?\.\S+)/ig, "[url]$1[/url]"); 


to
Code
Select All
	if(autolinkurls != 0) ubbcstr=ubbcstr.replace(/(^|\s+)((http:\/\/|www\.){1,}\S+?\.\S+)/ig, "$1[url]$2[/url]"); 

  
Back to top
 
IP Logged
 
deti
Legacy Dev Team
Development Team
****
Offline



Posts: 2,650
Location: Prien am Chiemsee, Germany
Re: [SVN] Images in Live Preview not displaying
Reply #1 - Jun 12th, 2009 at 4:18pm
Post Tools
Hmmmm, looks like it first parses the [img] tag and then the http://....

Carsten, can you give a look please? Here is the link to the SVN yabbc.js
http://yabb.svn.sourceforge.net/viewvc/yabb/public_html/yabbfiles/yabbc.js?revis...
  

Was immer Du tun kannst
oder erträumst tun zu können,
beginne es.
Kühnheit besitzt Genie,
Macht und magische Kraft.
Beginne es jetzt.
Whatever you can do
or dream you can,
begin it.
Boldness has genius,
power and magic in it.
Begin it now.
J. W. Goethe
Back to top
WWW  
IP Logged
 
Jet Li
Legacy Dev Team
Development Team
****
Offline



Posts: 6,588
Location: Hong Kong
[SVN] Images in Live Preview not displaying
Jun 12th, 2009 at 4:00pm
Post Tools
If I have images in img tag and click Live Preview, the image not showing up. Its display this:

Code
Select All
http://www.yabbworld.com/grafik/svn/svn-setup.png" alt="" border="0"> 



Click Preview Button will show correct and after Post Message.
« Last Edit: Jun 12th, 2009 at 4:00pm by Jet Li »  

PM me for YaBB Installation Service
Back to top
WWWGTalkFacebook  
IP Logged
 
Page Index Toggle Pages: 1
Topic Tools
 
  « Board Index ‹ Board  ^Top