Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/O Code)
 adding [iframe:x-y][/iframe] to forumcode
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 11 February 2004 :  14:48:37  Show Profile  Visit MarcelG's Homepage
I'm trying to find a way to add the iframe function to the forumcode.
The only thing I cannot seem to find out is how to define the size of the frame (height/width)...

The general idea would be this:
By using this code

[iframe:height-width-align]sourceaddress[/iframe]
you would get this HTML content:

<iframe src="sourceaddress" style="border:1px tablebordercolor solid;" name="framed1" scrolling="auto" frameborder="yes" align="align" height = "heightpx" width = "widthpx"></iframe>

Maybe someone has done this already ?

portfolio - linkshrinker - oxle - twitter

Edited by - MarcelG on 11 February 2004 14:50:13

ajhvdb
Junior Member

Netherlands
392 Posts

Posted - 11 February 2004 :  15:14:29  Show Profile
We added an new image tag for more control. The same as html .. we only replace the begin and end tag.

example:
[ image ]"logo.gif" border="0" align="right" width="145" height="94"[ /image ]
Go to Top of Page

ajhvdb
Junior Member

Netherlands
392 Posts

Posted - 11 February 2004 :  15:23:51  Show Profile
Oops, we didn't add the forum tag (it is standard), we changed the code.
Go to Top of Page

MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 11 February 2004 :  15:32:32  Show Profile  Visit MarcelG's Homepage
Ah, that's also an approach! Didn't think of that one! However, that requires some extra knowledge for the user on the syntax, and some extra tweaking of the HTML->Code functions, doesn't it ?

portfolio - linkshrinker - oxle - twitter
Go to Top of Page

ajhvdb
Junior Member

Netherlands
392 Posts

Posted - 11 February 2004 :  15:44:27  Show Profile
The code changes i can send you and if you use a compare tool installation is done in 2 min. You're right about the user off course.
Go to Top of Page

MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 12 February 2004 :  02:26:56  Show Profile  Visit MarcelG's Homepage
ajhvdb, thanks! You can send them to me at marcel@oxle.com.
But, still, how would we need to approach it if we wanted it to work as I described in my first post ? Any guru willing to take up the challenge ?

portfolio - linkshrinker - oxle - twitter
Go to Top of Page

DavidRhodes
Senior Member

United Kingdom
1222 Posts

Posted - 12 February 2004 :  04:31:16  Show Profile
Have a look at the Flash forum code mod, that uses exactly the same idea

The UK MkIVs Forum
Go to Top of Page

MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 13 February 2004 :  06:03:12  Show Profile  Visit MarcelG's Homepage
Mmmh...
I've found this :
inc_func_posting.asp

'---------- FLASH ICON
if strAllowFlash = "1" and mlev >= cInt(intAllowFlash) then
fString = replace(fString, "<embed width=""","[flash ", 1, -1, 1)
fString = replace(fString, """ height=""",":", 1, -1, 1)
fString = replace(fString, """ src=""","]", 1, -1, 1)
fString = replace(fString, """ hidden=""false"" autostart=""true"" loop=""false"" volume=""100""></embed>","[/flash]", 1, -1, 1)
end if
'---------- FLASH ICON

inc_func_common.asp
'---------- FLASH ICON
if strAllowFlash = "1" and mlev >= cInt(intAllowFlash) then
fString = doCode(fString, "[flash ",":","<embed width=""",""" height=""")
fString = doCode(fString, "]","[/flash]",""" src=""",""" hidden=""false"" autostart=""true"" loop=""false"" volume=""100""></embed>")
end if			
'---------- FLASH ICON

I'm not really sure that I understand how this function works...

portfolio - linkshrinker - oxle - twitter
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 13 February 2004 :  08:05:18  Show Profile
Try adding the following lines to the extratags function in inc_func_common.asp:
fString = doCode(fString, "[iframe", ":", "<iframe width=""", """ height=""")
fstring = doCode(fstring, "]", "[/iframe]", "src=""", """ iframe properties></iframe>")
The forum code would then look like this:

[iframe:w:h]url[/iframe]


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 13 February 2004 :  10:19:30  Show Profile  Visit MarcelG's Homepage
Mmmm...not quite...
This outputs this HTML code:"
<iframe width="" height="480:640src="<a href="url" target="_blank">url</a>" style="border:1px black solid;" name="framed1" scrolling="auto" frameborder="yes" align="left"></iframe>
Added this exact code to the function: (in red)
function extratags(fString)
	fString = doCode(fString, "", "", "<font color=""" & CColor & """>", "</font id=""" & CColor & """>")
	fString = doCode(fString, "[iframe", ":", "<iframe width=""", """ height=""")
	fstring = doCode(fstring, "]", "[/iframe]", "src=""", """ style=""border:1px black solid;"" name=""framed1"" scrolling=""auto"" frameborder=""yes"" align=""left""></iframe>")
	extratags = fString
end function

portfolio - linkshrinker - oxle - twitter
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 13 February 2004 :  11:21:50  Show Profile
Feck, of course it would; the URL is being caught by the edit_hrefs function in inc_func_common.asp. Only thing I can suggest at this hour of a Friday afternoon is removing that particualr fuunction. The problem with that is that any URLs that are posted without the [url] tag won't be clickable. I'm sure someone else will be able to come up with a better solution than that, though.


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 14 February 2004 :  03:23:03  Show Profile  Visit MarcelG's Homepage
ah..ok. No problem. I will try to hack it this weekend.

portfolio - linkshrinker - oxle - twitter
Go to Top of Page

MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 11 March 2004 :  05:10:33  Show Profile  Visit MarcelG's Homepage
I've done it ; I've placed the FLASH function with the IFRAME function.
It's still a bit buggy, but it works for what I need.

In inc_func_common.asp (around line 730)

		'---------- IFRAME
		if strAllowFlash = "1" and mlev >= cInt(intAllowFlash) then
		fString = doCode(fString, "[iframe ",":","<iframe width=""",""" height=""")
		fString = doCode(fString, "]","[/iframe]",""" src=""", """ style=""border:1px black solid;"" name=""framed1"" scrolling=""auto"" frameborder=""yes"" align=""left""></iframe>")
		end if			
		'---------- IFRAME


In inc_func_posting.asp (around line 140).
			'---------- IFRAME
			'if strAllowFlash = "1" and mlev >= cInt(intAllowFlash) then
			fString = replace(fString, "<iframe width=""","[iframe ", 1, -1, 1)
			fString = replace(fString, """ height=""",":", 1, -1, 1)
			fString = replace(fString, """ src=""","]", 1, -1, 1)
			fString = replace(fString, """ style=""border:1px black solid;"" name=""framed1"" scrolling=""auto"" frameborder=""yes"" align=""left""></iframe>","[/iframe]", 1, -1, 1)
			'end if
			'---------- IFRAME 


In inc_func_pb2.asp
Changed the function Flash:

function flash() {
	var text = getText();
	if (helpstat) {
		alert("Iframe Tag adds an external webpage or  Flash animation to the text.\n\nUSE: [iframe height:width]URL or Path to the page[/iframe]");
	} else if (basic) {
		AddTxt="[iframe width:height]" + text + "[/iframe]";
		AddText(AddTxt);
	} else {
		if (text) {
			txt=prompt("URL or Path to page or the Flash animation.",text);
		} else {
			txt=prompt("URL or Path to page or the Flash animation.","Text");
		}
		if (txt!=null) {
			AddTxt="[iframe height:width]"+txt+"[/iframe]";
			AddText(AddTxt);
		}
	}
}

portfolio - linkshrinker - oxle - twitter
Go to Top of Page

MarcelG
Retired Support Moderator

Netherlands
2625 Posts

Posted - 11 March 2004 :  05:14:58  Show Profile  Visit MarcelG's Homepage
By the way; a demo:
http://www.oxle.com/topic.asp?TOPIC_ID=878 (user demo, pw demo)

portfolio - linkshrinker - oxle - twitter
Go to Top of Page

Shaggy
Support Moderator

Ireland
6780 Posts

Posted - 11 March 2004 :  08:20:27  Show Profile
Looking good, Marcel; nice workaround. When you say it's a bit buggy, are there any specific issues you've encountered?


Search is your friend
“I was having a mildly paranoid day, mostly due to the
fact that the mad priest lady from over the river had
taken to nailing weasels to my front door again.”
Go to Top of Page

ajhvdb
Junior Member

Netherlands
392 Posts

Posted - 11 March 2004 :  10:41:07  Show Profile
On your site I posted a reply but it doesn't work in the reply?!?? Did i miss a letter, symbol.
Go to Top of Page
Page: of 2 Previous Topic Topic Next Topic  
Next Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.27 seconds. Powered By: Snitz Forums 2000 Version 3.4.07