How to show document preview in angularjs? - angularjs

I need a help to show the document's preview on the UI. It may be any kind of files(eg:.png, .jpeg, .txt, .pdf ...). When we click the download link from the angular client i need to open a dialog box with the file content as a preview to the user. We need something like gmail attachment. How to do that?
Thanks,

Try something. When you end up in trouble and you have some code to show and you need help with specific problem, then come back. This is not a place to ask people to do design work for you.

Related

DNN "Welcome to your new website" Pop Up

"Welcome to your new website" popup in DNN 7.2 and above shows some dynamic content. Its visible only to host users and doesn't reappears if "don't show this again" checkbox is checked once.
I need to develop something on similar lines where a popup should appear every-time a user of specific role(and some business logic) logs in. I think about creating a custom module and add it to all pages which could this for me but it seems welcome to your new site popup already tackles this.
Now I need to know if its somehow feasible to alter or extend this popup as per my need. I googled for some time and went through quick search in DNN code but haven't found anything convincing on this. Please suggest if what I think with this popup is feasible or I am searching in wrong path and creating custom module is my only way.
Thanks,
Ravi
I would think the best way to handle this would be with a custom skin object, and a custom module to manage the announcements.

Wijmo and Dotnetnuke 7. Has anyone tried it? Not working

Has anyone tried using the wijmo widgets in DNN 7.+ ?
For my example I'm trying to use the upload widget.
If I upload to a path on my server and test, it works (As in the dialog appears to choose a file... the popup)
If I load it within a page on the site, the button shows but nothing happens when clicked.
All script files and necessary markup are correct.
No console erros, nothing. Very confusing.
Wijmo widgets work in DNN 7.+.
The “action” option should be changed to the server’s address of upload.ashx file.
Note: the upload sample can’t be opened by file path(d:/……/upload.html), please make sure it is opened on server.
Thanks,
Richa

dotnetnuke: links to external files not working

We currently are running DotNetNuke 4.0.6. On the portals there are links that we have created to access files located on fileshares. When we set them up and save the page, then when we click that link nothing happens.
I have currently set the link up like this:
Link Type - URL
Protocol - Other
URL - file://///myfileshare/filesharename/folder1/folder2/myitem.pdf
If I select anything else (http, https, ftp) it doesn't work. When I mouse over the link it looks to be rendering correctly.
Can anyone help with why this may be happening? Am I missing a setting or selecting the wrong item?
The text in the editor is this:
Service Station for
Please remember the information presented in the newsletter is confidential and should not be shared outside the company.
Read more... (where "Read More" is the link)
There are a few items that you want to remember here.
Users need to have access to that share, so it is possible that could be your issue
It looks like you have a few extra //'s in your link. Should be file://, might need to switch to HTML view in the editor to modify.

ExtJS 3 export textarea content to a text file

I need to export the contents of an ExtJS TextArea to a text file. I searched around the documentation but I didn't find anything related to a textarea. Is this possible?
It would be also ideal to prepare the filename as well together with the ability to export the textarea content to the file.
Help is appreciated.
Thanks
You can't just save something from JS file into any place on user's local computer file system. It's huge security hole and it's just doesn't work this way. You have couple options however:
Send this information to your server and provide user with a link to a file. User clicks that link server will respond with the information - browser saves that data. You can even make so content will automatically be downloaded by the browser (well, by most of them anyway)
Or you can ask user to right click and copy this information into the clipboard.

How to auto generate a webpage after user submits form

I am looking for some initial direction on this one because I cannot seem to find my way with it. Let me explain...
I am developing a website wherein a logged in site member (Joomla 1.6) can fill out a simple form and attach a pdf to be uploaded upon submission. The user then clicks the submit button and the page will refresh to a new and unique web page.
User Submits data on http://www.examplesite.com and then after submission a new web page is generated that is called http://www.examplesite.com/userSubmittedValue
This newly generated web page would come from a template that is specified by the administrator and, most important, it will display all of the information that the user submitted. Also, there would be a link to download the pdf they uploaded. The user could then view a list of all the pages they have created in this manner via their profile.
I have seen this all over, but I am at a loss for how to generate this. Any help is much appreciated.
This is not something you will be able to easily do or get a detailed answer for here. If you just wanted to do the submission form with a thank you page that shows the data submitted you could use any number of form wizard type extensions - http://extensions.joomla.org/extensions/contacts-and-feedback/forms
If you just needed a way for users to upload PDfs and have access to them you could use one of the file management extensions that offer front end upload features - http://extensions.joomla.org/extensions/directory-a-documentation/downloads
If the additional data that is being submitted is simply data related to the file - title, description, etc then one of the file download components should work fine for you. The choices are limited in 1.6 at this time though so you might have to go with 1.5 to get the extension that works best for your needs.
So this probably isn't the best way to do it if your using Joomla but it just might help.
I would use PHP and inside of you're directory have a file like "template.html". Then I would create some php to handle the task of....
Opening "template.html"
Finding and replacing the values that the user passed you
Save the "template.html" under a new name (userSubmittedValue.html)
Again, I never really use Joomla. If you were to try this I'd suggest checking out php's file system functions (http://us2.php.net/manual/en/ref.filesystem.php).
Hope this helps a bit.

Resources