Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 15 of 15
  1. #1
    New to the CF scene
    Join Date
    Mar 2004
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Having trouble getting no right click to work in a pop up window..

    Hi. My site freddien.com is a personal page for me mostly to put my pictures on. I have a picture album java script on there and it opens a picture to its full size when the thumbnail picture is clicked. The problem im having is that when the regular size picture is loaded in the pop up window it allows users to right click and they can get the images off my site. I was wondering if someone could help me fix this so that wont happen. Below i will post the part of the script that dose the pop up window. If you dont understand what i mean please view the scripted located on my page at www.freddien.com/photoalbum/photoalbum.html


    }
    function SuzyPicRemote(picName) { // Pops up the photo in a remote window.
    ShowingImage = new Image();
    ShowingImage.src = picName;
    wid = ShowingImage.width + 50;
    hei = ShowingImage.height + 60;
    if (wid < 30 || hei < 30) {
    wid=650;
    hei=490;
    }
    if (screen.width < wid || screen.height < hei) {
    wid = screen.width - 50;
    hei = screen.height - 50;
    }
    OpenWindow = window.open("", "remoteWin", "resizable=1, scrollbars=1, toolbar=0, left=15, top=10, width=" + wid + ", height=" + hei);
    OpenWindow.document.open();
    OpenWindow.document.write('<html><head><title>' + ActiveArray[current].TitVal + '</title></head>'
    + '<body style="background:url(parchment.jpg); font:8pt verdana; margin:2px"><center>' + ActiveArray[current].DatVal + '<br>'
    + '<img src=' + picName + '><br>' + ActiveArray[current].TxtVal
    + '<br><a href="javascript:window.close();">close window</a></center></body></html>');
    OpenWindow.document.close();
    }

    Below is my no right click script

    <script language="JavaScript">
    IE4plus = (document.all) ? true : false;
    NS4 = (document.layers) ? true : false;

    function clickIE()
    {
    return false;
    }

    function clickNS(e)
    {
    if (e.which==2 || e.which==3)
    {
    return false;
    }
    }
    if (!IE4plus)
    {
    document.captureEvents(Event.MOUSEDOWN || Event.MOUSEUP);
    document.onmousedown=clickNS;
    document.onmouseup= clickNS;
    document.oncontextmenu=clickIE; // For NS 6+
    }
    else
    {
    document.onmouseup= clickIE;
    document.oncontextmenu=clickIE;
    }

    </script>

    Thanks Freddie
    Last edited by Freddie1275; 03-15-2004 at 01:26 AM.

  • #2
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    You can't really protect the images on the site. Blocking source codes by means of disabling right click and any other means has been discussed extensively in this forum. Refer to the "block source codes" link in my sig.

    If you really want to protect your images, put a watermark in the images.
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #3
    New to the CF scene
    Join Date
    Mar 2004
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Im not trying to keep them extra safe or anything like that and dont want water marks ect... All i want is so when that window pops up u cannot right click in that window. Theyc an still view the source if they want thats ok. I just need to know how to add no right click to the window that pops up with the big picture.. Someone please help.

  • #4
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    That would pose a big accessibility problem since right-clicking the mouse in the document provides several menus with different functionalities in it.
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #5
    New to the CF scene
    Join Date
    Mar 2004
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Again, my site is not commerical its private for me and a few others. I dont care about menu ect.... Can someone just tell me how i would add it.

  • #6
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts

    Use at your own risk

    <img src="..." oncontextmenu="return false">

    You may want to also prevent the IE6 image toolbar that displays when you mouse over images.

    <meta http-equiv="imagetoolbar" content="no" />
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #7
    Banned
    Join Date
    Sep 2003
    Posts
    3,620
    Thanks
    0
    Thanked 0 Times in 0 Posts
    No wonder you want to disable right clicking and view source.
    You don't want people to see that you are violating their copyrights by removing the credits from the scripts you are using.

    Do these credits for your picture show look familar?
    Which is on your page and the credits are removed.


    <!-- This script and many more are available free online at -->

    <!-- The JavaScript Source!! http://javascript.internet.com -->

    <!-- Original: Susan K. (kitykity@hotmail.com) -->

    <!-- Web Site: http://www.kitykity.com/photoalbum -->

    <SCRIPT LANGUAGE="JavaScript"> var javascript_version = 1.0;</SCRIPT>

    <SCRIPT LANGUAGE="JavaScript1.1"> javascript_version = 1.1;</SCRIPT>



    <script language=javascript>

    /**********************************************************

    * Suzy's Javascript Photo Album, version 5.5, March 2, 2003

    *

    * Changed this version: can now use HTML tags in picture description.

    *

    * This javascript code may be used on other Websites if:

    * 1) This notice is left unchanged.

    * 2) A link to http://www.kitykity.com is placed on that page.

    * Please search the FAQ for answers to common problems and questions.

    * You may contact me at kitykity@hotmail.com for assistance.

    *

    **********************************************************/


    A link to the script provider can be found below.
    http://javascript.internet.com/miscellaneous/kitykity's--photo-album.html

    I suggest you return the credits to the page as you agreed to when you used the script.

    .....Willy

    Edit: Tried to fix the link and I may as well add the O/P's link
    http://www.freddien.com/photoalbum/photoalbum.html
    Last edited by Willy Duitt; 03-15-2004 at 03:28 AM.

  • #8
    New to the CF scene
    Join Date
    Mar 2004
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Maybe if you would know that i sent the lady 10 dollars to get her tags off.? You just jump to think ignorant stuff.. GO to her homepage and if you donate you can remove tags... Now do you know how to fix my problem?

  • #9
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    I already provided you with the solution in my above post.
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #10
    New to the CF scene
    Join Date
    Mar 2004
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Thanks glenngv

    Thanks glenngv it worked great. But is there also a way i can make it so they cant right click the page the image is on? If not its ok but thanks again

  • #11
    Supreme Master coder! glenngv's Avatar
    Join Date
    Jun 2002
    Location
    Philippines
    Posts
    11,068
    Thanks
    0
    Thanked 256 Times in 252 Posts
    It's possible but it's better to leave it like that.
    Glenn
    ____________________________________

    My Blog
    Tower of Hanoi Android app (FREE!)
    Tower of Hanoi Leaderboard
    Samegame Facebook App
    vBulletin Plugins
    ____________________________________

  • #12
    Banned
    Join Date
    Sep 2003
    Posts
    3,620
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Originally posted by Freddie1275
    Maybe if you would know that i sent the lady 10 dollars to get her tags off.? You just jump to think ignorant stuff.. GO to her homepage and if you donate you can remove tags... Now do you know how to fix my problem?
    Well I looked thru the authors site and although there was a "Would you like to donate" paypall link. There was no mention of removing the credits if you donated. Although I can not understand why the author would agree to removing the credits in return for a donation. I suppose it is very much possible that this is included in a "Thank You for your donation" confirmation.

    Either way, I emailed the author and requested clarification.
    If and when I recieve a reply. I will post the results.

    .....Willy

  • #13
    New to the CF scene
    Join Date
    Mar 2004
    Posts
    6
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Alright thats fine. You just made your self look stupid and your trying to find a way to cover it up.

  • #14
    Banned
    Join Date
    Sep 2003
    Posts
    3,620
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Originally posted by Freddie1275
    Alright thats fine. You just made your self look stupid and your trying to find a way to cover it up.
    Freddie;

    I recieved a reply and your donation does not grant you explicit permission to remove the credits.

    In part the Author states:
    (I will post the entire response once I recieve permission to do so)
    Since the page is not being used for a commercial purpose, I do not have a problem with him removing the credit from showing on the page. If a link is still commented in the code, that is just fine.
    Although the author does not seem to mind you removing the credits. She does expect that you leave a link to her site either in the script or on your page.

    Please make the appropriate changes as soon as possible.

    .....Willy

  • #15
    Regular Coder
    Join Date
    Jun 2002
    Location
    The Planet Earth Code Poet: True
    Posts
    282
    Thanks
    0
    Thanked 1 Time in 1 Post
    This thread look as if it has served its purpose. I am going to close it now to avoid any further conflict.

    Accusations and backlashing are not the kind of things that make this a productive forum.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •