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/Code)
 i made update for format code
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 2

Ez4arab
Junior Member

479 Posts

Posted - 10 July 2001 :  13:04:52  Show Profile  Visit Ez4arab's Homepage
i made some change in the format code which is marquee and ifram you have add these secrpit as following:

Make backup for the following pages

inc_function.asp
inc_post_buttons.asp
icon_code.asp

Yom may need these picture download them
icon_htm_page.gif
icon_marquee.gif
rename file to icon_flash

#################inc_function################
' ADD MARRQUEE & Ifram LINE 268
fString = replace(fString, "<marquee>","[marquee]", 1, -1, 1)
fString = replace(fString, "</marquee>","[/marquee]", 1, -1, 1)
fString = replace(fString, "<iframe src=""", "[iframe]", 1, -1, 1)
fString = replace(fString, """ width=450 height=150 border=0></iframe>", "[/iframe]", 1, -1, 1)
fString = replace(fString, "<embed src=""", "[flash]", 1, -1, 1)
fString = replace(fString, ".swf"">", "[/flash]", 1, -1, 1)



' ADD MARRQUEE and Ifram LINE 483
fString = doCode(fString, "[marquee]","[/marquee]", "<marquee>", "</marquee>")
fString = doCode(fString, "[iframe]", "[/iframe]", "<iframe src=""", """ width=450 height=150 border=0></iframe>")

fString = doCode(fString, "[flash]", "[/flash]", "<embed src=""", ".swf"">")


'Add flash code in line 485
########## add this in inc_post_buttons.asp line#48 ############

noramly you can save picture of flash by right click save picature as



rename file to icon_flash

<a href="Javascript:iframe();"><img src="icon_htm_page.gif" width="22" height="22" alt="insert page" border="0"></a><a href="Javascript:marquee();"><img src="icon_marquee.gif" width="22" height="22" alt="marquee" border="0"></a>
<a href="Javascript:flash();"><img src="icon_flash.gif" width="22" height="22" alt="insert flash" border="0">



####### Add this code in the file Icon_code.asp in the line # 296######
function iframe() {
if (helpstat){
alert(" Add yor commont about this alert ");
} else if (basic) {
AddTxt="[iframe][/iframe]";
AddText(AddTxt);
} else {
txt=prompt("URL for page","http://");
if(txt!=null) {
AddTxt="[iframe]"+txt+"[/iframe]";
AddText(AddTxt);
}
}
}
function marquee() {
if (helpstat){
alert(" Add yor commont about this alert ");
} else if (basic) {
AddTxt="[marquee][/marquee]";
AddText(AddTxt);
} else {
txt=prompt("Add Your Marquee Text","");
if(txt!=null) {
AddTxt="[marquee]"+txt+"[/marquee]";
AddText(AddTxt);
}
}
}


function flash() {
if (helpstat){
alert(" Add you flash with out .swf ");
} else if (basic) {
AddTxt="[flash][/flash]";
AddText(AddTxt);
} else {
txt=prompt("URL for page","http://");
if(txt!=null) {
AddTxt="[flash]"+txt+"[/flash]";
AddText(AddTxt);
}
}
}


Edited by - aljish on 11 July 2001 11:23:25


Edited by - aljish on 12 July 2001 04:46:07

Edited by - aljish on 12 July 2001 16:25:53

Edited by - aljish on 12 July 2001 16:35:53

Edited by - aljish on 13 July 2001 09:02:49

Ez4arab
Junior Member

479 Posts

Posted - 10 July 2001 :  14:59:41  Show Profile  Visit Ez4arab's Homepage
i forget to put the picture
you can download it form this link click here

Go to Top of Page

Intrepidone
Average Member

Canada
515 Posts

Posted - 10 July 2001 :  17:51:32  Show Profile
quote:
function ifram() {
if (helpstat){
alert(" Add your comment about this alert ");
} else if (basic) {
AddTxt="[ifram][/ifram]";
AddText(AddTxt);
} else {
txt=prompt("URL for page","http://");
if(txt!=null) {
AddTxt="[ifram]"+txt+"[/ifram]";
AddText(AddTxt);
}
}
}


I think you left out 4 e's . You have ifram that should be iframe.

function ifram() {
if (helpstat){
alert(" Add your comment about this alert ");
} else if (basic) {
AddTxt="[iframe][/iframe]";
AddText(AddTxt);
} else {
txt=prompt("URL for page","http://");
if(txt!=null) {
AddTxt="[iframe]"+txt+"[/iframe]";
AddText(AddTxt);
}
}
}


Intrepidone
Go to Top of Page

aston
New Member

Andorra
51 Posts

Posted - 10 July 2001 :  20:02:17  Show Profile
and the IFRAME does not work,hehe!

______________________

Fly me to the Moon
Go to Top of Page

Intrepidone
Average Member

Canada
515 Posts

Posted - 10 July 2001 :  21:10:25  Show Profile
quote:

and the IFRAME does not work,hehe!

______________________

Fly me to the Moon




Yea, if I remember correctly an iframe needs a src=" tag in it so it would have to look something like this

[iframe src="http://www.yourdomain.com/file.html"][/iframe]

See if I can add something to the source , but it won't work with Netscape

Intrepidone
Go to Top of Page

Ez4arab
Junior Member

479 Posts

Posted - 11 July 2001 :  10:45:59  Show Profile  Visit Ez4arab's Homepage
thanx Intrepidone you are right. it donot work with NETSCAPE but it works ok with IE.
i test these scrpit it works fine in my computer when i up load to my forum it is not working. DO THINK if add this scr will work fine. if yuo test it tell me.



Go to Top of Page

Ez4arab
Junior Member

479 Posts

Posted - 11 July 2001 :  11:04:42  Show Profile  Visit Ez4arab's Homepage
i am not expert in the asp but it is my first try

i do this

if strIFRAMEInPosts = "1" then fString = replace(fString, "<iframe src=""","[iframe]", 1, -1, 1)
fString = replace(fString, """ border=0>","[/ifame]", 1, -1, 1)
end if

fString = doCode(fString, "[iframe]","[/iframe]","<iframe src=""",""" border=0>")

any one who expert in the asp can check this if any wrong





Edited by - aljish on 11 July 2001 11:39:14
Go to Top of Page

stuF
Average Member

United Kingdom
561 Posts

Posted - 11 July 2001 :  14:12:26  Show Profile  Visit stuF's Homepage
i like the iframe idea, youre right, you can restrict/select height and width etc.
only problem is that they just do not work in NS...:
Go to Top of Page

z-man
Starting Member

Netherlands
41 Posts

Posted - 11 July 2001 :  14:27:55  Show Profile
Let's face it, more than 90 percent of the people are using IE 4.0 and higher.

Go to Top of Page

Intrepidone
Average Member

Canada
515 Posts

Posted - 11 July 2001 :  14:35:05  Show Profile
quote:

i like the iframe idea, youre right, you can restrict/select height and width etc.
only problem is that they just do not work in NS...:




Like what Zman said, it's true. I have my stats report emailed to me every night and around 85 - 90% use IE.

Netscape has been around for a LONG time and you would think they would incorporate something as easy as an iframe in their browser code. I use to use iframes about 5 years ago in some designs but back then it was not feasable because the market was more 50/50.

aljish,

Great job here, I really like the looks of how you can use an iframe in a Post.

Keep up the good work eh!

Intrepidone
Go to Top of Page

stuF
Average Member

United Kingdom
561 Posts

Posted - 11 July 2001 :  15:15:01  Show Profile  Visit stuF's Homepage
true i suppose, im the biggest culprit for not recognising NS users, my site is totally NS incompatable...
i would be wary of this mod for one reason though, when you allow a person to post a file on oyur site, oyu cut the step of the person having to click the link.
now no matter how hard some of us try, our boards cannot be 24 guarded from undesired content.
when a person comes to my site i like to give them the option to look at what they want...i can only think of one way around tihs, a profile option to allow/disable iframes for certain users.
Simillar sorts of things have been discussed for no graphics etc.
not a big idssue, but one i would consider before adding this to my site!

Go to Top of Page

Intrepidone
Average Member

Canada
515 Posts

Posted - 11 July 2001 :  15:25:31  Show Profile
My site is close to 99% Netscape Compatible (is was 99.9% but not now with the iframe ) I have gone through almost all the forum code and MODS where I found problems with Netscape and fixed them (probably find some more though), and I don't even use Netscape, but you have to keep both worlds happy.

As far as "undesired content" goes, a person could just insert an image, make a Hyper Link
or just send a Post full of %$@#@!&%, so having iframes will not add to undesired content.

Using the iframes will just enhance things for IE users, so your not really leaving Netscape users out, it will just show up to Netscape users as a link to click on, basically the same way as clicking on the "Insert Hyperlink" button in the Post Buttons

Intrepidone

Edited by - Intrepidone on 11 July 2001 15:29:26
Go to Top of Page

Intrepidone
Average Member

Canada
515 Posts

Posted - 11 July 2001 :  17:27:57  Show Profile
ok aljish, this is what I have now for iframe and it works

If anyone wants to see a working version click here

If you wanted to edit a Post that used the iframe, it would leave the <iframe> and </iframe> tags in the Post to, so you would have to backspace that out. It is fixed in this new code. Also, you can set a default size you want the iframe to be.

################ Add this code in Inc_functions.asp #####################
Iframe LINE 268

       fString = replace(fString, "<iframe src=""", "[iframe]", 1, -1, 1)
fString = replace(fString, """ width=450 height=150 border=0></iframe>", "[/iframe]", 1, -1, 1)


and Iframe LINE 483
       fString = doCode(fString, "[iframe]", "[/iframe]", "<iframe src=""", """ width=450 height=150 border=0></iframe>")



################ add this in inc_post_buttons.asp line#48 ################
<a href="Javascript:iframe();"><img src="icon_htm_page.gif" width="22" height="22" alt="insert page" border="0"></a> 



################ Add this code in the file inc_code.asp in the line # 296

function iframe() {
if (helpstat){
alert(" Add your comment about this alert ");
} else if (basic) {
AddTxt="[iframe][/iframe]";
AddText(AddTxt);
} else {
txt=prompt("URL for page","http://");
if(txt!=null) {
AddTxt="[iframe]"+txt+"[/iframe]";
AddText(AddTxt);
}
}
}



If someone wishes to make this an Admin or Moderator only option they can just change the inc_post_buttons.asp to this
######To make the button an admin only option inc_post_buttons.asp line#48 #######
<% if mlev = 4 or mlev = 3 then %>
<a href="Javascript:iframe();"><img src="icon_htm_page.gif" width="22" height="22" alt="insert page" border="0"></a>
<% end if %>


Intrepidone

Edited by - Intrepidone on 12 July 2001 06:50:28
Go to Top of Page

Intrepidone
Average Member

Canada
515 Posts

Posted - 11 July 2001 :  19:43:20  Show Profile
Just so everyone knows, Netscape 6.1 DOES support the <iframe> </iframe> tag.

I could not believe it when I read it, so I installed 6.1 and it does

Intrepidone
Go to Top of Page

Ez4arab
Junior Member

479 Posts

Posted - 12 July 2001 :  16:11:48  Show Profile  Visit Ez4arab's Homepage
i made updata for this code now you can allow flash code in the form the only problem that i encounter is the witdh and hight. i think there is a jave scrpit to do this. Any one have it <<< plz tell me >>>
#################inc_function################
' ADD flash LINE 273
fString = replace(fString, "<embed src=""", "[flash]", 1, -1, 1)
fString = replace(fString, ".swf"">", "[/flash]", 1, -1, 1)

'Add flash code in line 485
fString = doCode(fString, "[flash]", "[/flash]", "<embed src=""", ".swf"">")

########## add this in inc_post_buttons.asp line#48 ############

noramly you can save picture of flash by right click [b]save picature as



rename file to icon_flash

<a href="Javascript:flash();"><img src="icon_flash.gif" width="22" height="22" alt="insert flash" border="0">


[b]####### Add this code in the file Icon_code.asp in the line # 296######

function flash() {
if (helpstat){
alert(" Add you flash with out .swf ");
} else if (basic) {
AddTxt="[flash][/flash]";
AddText(AddTxt);
} else {
txt=prompt("URL for page","http://");
if(txt!=null) {
AddTxt="[flash]"+txt+"[/flash]";
AddText(AddTxt);
}
}
}



Edited by - aljish on 12 July 2001 16:16:58

Edited by - aljish on 13 July 2001 09:05:31
Go to Top of Page

Intrepidone
Average Member

Canada
515 Posts

Posted - 13 July 2001 :  08:07:34  Show Profile
aljish,

I did do a flash example over at Techcare2000 test site

I am not sure if I would use this one. I am unfamiliar with Flash and don't know if someone could use this against the forum in a malicious way? If I did I think I would keep this one as an Administration only option as so members would not swamp the forum with Flash.

You do have 1 typo in your code
<a href="Javascript:falsh();"><img src="icon_flash.gif" width="22" height="22" alt="insert flash" border="0">


should read

<a href="Javascript:flash();"><img src="icon_flash.gif" width="22" height="22" alt="insert flash" border="0">


Intrepidone

Edited by - Intrepidone on 13 July 2001 08:13:19
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.17 seconds. Powered By: Snitz Forums 2000 Version 3.4.07