|
|
#1 (permalink) |
|
Junior Member
Join Date: May 2008
Posts: 6
|
I have set this up so that I have multiple galleries whereby a new swf file is loaded in by way of a separate nav bar I've created. My problem is that I want some of the galleries to allow the user to save the images, and some of the galleries I do not. So, I put the .fla files of the galleries I want to save image into one directory along with the .as files, and then the others into their own folder with the .as files. I then changed the picture.as file code to:
// allow image save private var allowSave:Boolean = false; I then published each of those files that I wanted to not be able to save. All the .swf files reside in the same directory on the server. The problem I'm having is that it is not working. Seems no matter what I do, it still allows the user to save the image. Is there something that I'm missing? Is there something else I need to change? thanks for your help. This is a fantastic gallery, by the way. |
|
|
|
|
|
#2 (permalink) |
|
OYXLUSFlash.com Staff Member
|
This can be fixed easely.Open the Picture.as file and search for the methods named addSave() and addSaveDisabled(). At the top of this functions just write the following line:
Code:
if(!allowSave) return; It should look like this: Code:
private function addSave() {
if(!allowSave) return;
..............................
}
private function addSaveDisabled() {
if(!allowSave) return;
..............................
}
|
|
|
|
|
|
#3 (permalink) |
|
Junior Member
Join Date: May 2008
Posts: 6
|
huh. tried that. still have the same problem.
The way I have it setup is the default for the page(s) is set to not allow save image. If they right click on the image, the context menu reads: "save is disabled, please login to save images" but it still allows me to save the image. If I login (which just loads a new version of the same page, but made with the picture.as set to false for the saveimage thing, it still reads the same way: "save is disabled, please login to save images" when the message I put in the private var sistr:String = "save image" it's as if it is not reading the picture.as file correctly. I know that it is loading the new .swf file because there are some different graphics on that version. Any idea why this isn't working? I really appreciate your help. |
|
|
|
|
|
#4 (permalink) |
|
Junior Member
Join Date: May 2008
Posts: 6
|
so if I login before I go to this section, it acts correctly. It shows the context menu as "save image"
If I login after I go to this section, it reads as I described in the previous post. weird. But, at any rate, it still allows the save even on the the files I set the save image to false on. |
|
|
|
|
|
#9 (permalink) |
|
Junior Member
Join Date: May 2008
Posts: 6
|
So, I created a login button to change from the versions without the ability to save, to the versions where you can save. By clicking on the login button, and logging in, it loads new versions of the swf files with the picture.as file set to the save feature as true. In the picture.as code, there's a line where you can edit what the contextual drop down menu reads. (line 15 in the code - private var sistr:String = "save image..."; ) The default was set to "save image". On the version where I want to disable the save image feature, I couldn't get it to work, (if I set the save image to false, (line 13 in code) I can still see the drop down menu, so I changed the string to read "save is disabled...)
so I know it has loaded the swf that I made with the save feature disabled, but the save feature is not getting disabled. I can still save the image. |
|
|
|
![]() |
| Bookmarks |
«
Previous Thread
|
Next Thread
»
| Thread Tools | |
| Display Modes | |
|
|
All times are GMT. The time now is 07:56 PM.









Linear Mode
