While doing a migration of tridion 5.2 to Tridion 2011 SP1 HR1, we noticed that there isn't a upload folder in the Tridion 2011 content manager directory.
The upload folder of Tridion 5.2 used to contain all files that where uploaded as a multimedia component, even before they where stored in Tridion.
Since our image crop-tool used this directory, is there a way of making this folder available in Tridion 2011?
The upload directory is still used, but for security reasons it was moved outside of the web application (C:\Temp by default I believe).
You can configure it, though -- it's the Tridion.UploadDirectory element in System.config.
To find the MIME type based on the data of the file see the following post:
Using .NET, how can you find the mime type of a file based on the file signature not the extension
But depending on what you want to do with the file before it is created within the repository there might be much more elegant solutions, e.g. the event system.
Related
Imagine that a user uploads a file called "myAssignment.docx" to Moodle to complete the submission of an assignment. Where would the folder containing "myAssignment.docx" be? Is it in the moodledata folder outside the public web directory or somewhere else? I am trying to locate that folder because I want to monitor its growth to determine when I should upgrade my web hosting service to provide more storage space for files that students upload to the server.
https://docs.moodle.org/dev/File_API_internals#File_storage_on_disk
The simple answer is inside:
$CFG->dataroot.'/filedir'
It is stored in /repository directory from Ver 3.62.
You may have subdirectories. Check which one is used for the purpose.
I am building a internationalized app on iOS, where the app suppose to download a few images from the server (say 01.png, 02.png, 03.png, 04.png, where 01 and 03 are the English version of 2 images, and 02 and 04 are the Chinese version of 2 images).
I know how to set internationalization locally (naming both files to the same name, and put one to en.lproj folder and the other one to zh-Hant.lproj folder).
I'm just wondering is there a better way to do this programatically?
or I'll have to programatically download from server -> put files in their language dependend server-> rename ?
P.S. I do not have control of the server, so renaming files from server will not be an option. those image files are shared between iOS and Android devices. (I know Android append language and resolution specific text to the file name)
You need to manage the download and usage of these files yourself. The standard localisation system is based upon resources which are part of the main bundle. You (broadly speaking) have 2 options:
Download the individual files, name them and store them in the cache folder (probably not the documents folder as this content doesn't need to be backed up), load them yourself as required by referring to the appropriate name.
Download a prepared bundle which contains the strings and images you want to use for the localised app. Use a combination of NSLocalizedStringFromTableInBundle and a custom implementation similar to imageNamed: (throughout your app) so you can obtain resources from the specified bundle.
You need to mediate between content in the main bundle and your additional storage.
I have a website, let's say it's "http://www.jwilkthings.com/stuff"
I have a bunch of .txt files stored on this website, i.e. "http://www.jwilkthings.com/stuff/text1.txt"
What I'm wanting to do is find a way in iOS to download all of those text files without knowing what the document name is. I can already retrieve them manually as long as I have a file name, but I would rather just get all of them at once and put them in the documents directory if possible. I currently use FileZilla to upload all of the text files, so I can use FTP if needed.
The correct way to solve this problem is to not use FTP (riddled with performance and security issues), and to configure your web server to expose a table of contents directory listing that your client can parse.
But that's not an answer to your question.
If you really want your iOS app to speak FTP, take a look at the SimpleFTP sample project from Apple.
It's old, but I just got it to build on iOS 5. The ListController.m file has the code you're looking for.
I want to convert my struts2 web application into an exe format so that exe file will load my project into server and database into MySQL.
Are there any such tools available for loading files into a folder?
Are there any forms other than .exe to which I could convert my project to do this action?
Is it possible to decrypt the code from class file to java file?
Which is the most secure form for a struts2 project for loading into a server?
You want to convert it to executable one?? generally installer came to assist auto installation like if you have created a product using all these technology and you want save your customer from all the setting and installation processes like database configuration,other configurations etc.
Is it possible to decrypt the code from class format to java format
there are many java d-compilers available which help you to convert .class files to java files though they sometime fails to convert it 100% but in most cases they tend to show some one what they actually want to see.
You can't load an exe file into a web server.
I suppose you could create an executable that includes a server and your war file, but I would strongly discourage the practice.
You could obfuscate (e.g., with ProGuard) and/or encrypt your .class files, but if they're determined to get to your unobfuscated byte code, they almost certainly will.
If they're not that determined, then it's probably not important enough to go through all the effort, debugging, and so on.
I load up a few XML files with my app in Mono when deploying to iPhone. I edited one of those XML files in Windows through a LAN connection to the Mac on which the file resided. After editing the xml file the app seems to refuse the xml file exists anymore. THe properties are still 'copy always' and 'content' where relevant for the XML file, I know it exists and I can even open and edit it MonoDevelop. But in app isolatedstorage.fileexists("filename.xmL") ALWAYS returns false.
I deleted the file and daded it back in, I copy+pasted the file, heck, I even renamed another xml file to the same filename and that xml file stopped being recognized.
Not sure what to do now?
Did you try "File.Exists" ?
Keep in mind that IsolatedStorage's main goal is to isolate the files from outside (the application) usages. As such MonoDevelop will copy to the application folder, but not in the isolated storage. Same is true for desktop applications, MonoMac apps...
FWIW IsolatedStorage API exists in MonoTouch to help you port existing code (from the 'desktop' framework or WP7) but there's no reason (beside portability) to use it. In iOS applications are already isolated (from each other) and so are their files.