Not planned build "Bookmarklet" into Editor for full Drag & Drop capability

erich37

Well-known member
Suggestion:

build a "Bookmarklet" directly into the Editor for full "Drag & Drop" capability of images and associated image-URLs.

Bookmarklets are very well known to be used in your Browser-Bar.
But what about adding this "functionality" directly into the Editor ?


So it would not be a "Browser Bookmarklet", but an "Editor Bookmarklet".


Would it work technically ?
 
Upvote 0
This suggestion has been closed. Votes are no longer accepted.
it would do exactly the same as commonly known "Browser Bookmarklets".

But you would not drag the "Bookmarklet" into your Browser-Bar.


This "Bookmarklet" would be built into the Redactor-Editor directly and would work Browser-independent.


I have not come across anything like that yet, but I think it would give Forums a groundbreaking leap forward.....


:)
 
Last edited:
What do you define as a 'bookmarklet'? The definition of a bookmarklet is:
A bookmarklet is a bookmark stored in a web browser that contains JavaScript commands to extend the browser's functionality.

Not discrediting the suggestion, I'm just failing to see what it's suggesting.
 
What do you define as a 'bookmarklet'? The definition of a bookmarklet is:
Not discrediting the suggestion, I'm just failing to see what it's suggesting.

To view this content we will need your consent to set third party cookies.
For more detailed information, see our cookies page.


The question is:
- Would it work from a logical and also from a technological perspective ?


The idea is that you actually do not have that JS-Snippet in your Browser-Bar, but you have this capability (and this JS-Snippet code) directly within the Redactor-Editor.



Some Links:
http://coding.smashingmagazine.com/2010/05/23/make-your-own-bookmarklets-with-jquery/

http://stackoverflow.com/questions/...like-pinterest-snatchly-that-can-scrap-images

http://thecodepost.in/internet/get-the-official-twitter-share-bookmarklet

https://dev.twitter.com/docs/share-bookmarklet

:coffee:
 
I don't think it would work from any stand point. Here's the bookmarklet I have in my browser bar right now:
Code:
javascript:(function()%7Bph='[redacted]';s0=document.createElement('SCRIPT');s0.type='text/javascript';s0.src='http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js';s=document.createElement('SCRIPT');s.type='text/javascript';s.src='http://private';document.getElementsByTagName('head')%5B0%5D.appendChild(s0);document.getElementsByTagName('head')%5B0%5D.appendChild(s);%7D)();

This takes the current page and texts it to my phone. The tweet button takes the current page URL and tweets it. I'm not exactly sure what the Pin It bookmarklet does, since I don't use Pinterest. However, bookmarklet is a broad term and can be for any functionality as defined. I have yet to see you actually answer the question of what you want this bookmarklet to do, before a 'can it work' is even determined.

However, I don't think it will work because it'll only have access to your current page, not a different one, so it will be rather limited it functionality.
 
Example:

let's say you have 2 Browser-windows open and shown on your computer:

- 1 Browser-window shows http://xenforo.com/community/forums/general-xenforo-discussion-and-feedback.45/create-thread
- 1 Browser-window shows some other page, e.g.: http://www.shashca.com/2013/05/sooraj-aj-218p-m-pe-hoga-khana-kaaba-k-oper/


Process:
1)
You are at the xenforo-website and click onto the "Bookmarklet Button" in the XenForo-Editor.

2)
the Bookmarklet automatically detects the images at the other Browser-window, e.g.: this one http://www.shashca.com/2013/05/sooraj-aj-218p-m-pe-hoga-khana-kaaba-k-oper/

3)
The Bookmarklet automatically pulls the images of that other browser-window into the XenForo-Editor.

4)
Now you select which images from that second website you want to display in the Editor.

5)
You click "Post Reply" at the XenForo-Editor and the selected image gets posted at the XenForo-website.


:coffee:
 
Now that we have a valid suggestion in here (on the functionality), I can say that it won't be technically possible. Unless there's some fancy JavaScript hack that I am not aware, JavaScript has access to the 'window' (the current page) and nothing else. Browsers have started segregating different pages into different processes which would make the situation even more complicated on the code end.

It gets even muddier when you have more than one window open. I currently have 6 tabs open, which one does the images get pulled in from? Feasibly, this can't be implemented.
 
Now that we have a valid suggestion in here (on the functionality), I can say that it won't be technically possible.


come on KK...... everything is technically possible nowadays.


If you are a good with computer, you can even put MP3 into a watch :p;)


To view this content we will need your consent to set third party cookies.
For more detailed information, see our cookies page.



Anyway, not sure if the process I described above makes any sense at all or if it should be totally different.
But I guess you get the basic idea..... :cautious:

Brainstorming for innovation.....
 
It makes sense (once you defined what functionality you were actually suggesting). In the manner you are suggesting, it's fairly impossible. Your current window only has access to itself, any JavaScript has access to the HTML of the current page.

And it becomes even more difficult once browsers start segregating processes + more tabs. Ripe for an add-on to take a URL, fetch any images and display them. Not something I'd like to see in the core tho.
 
well, I guess there is a "reason" all the other guys are making "Browser Bookmarklets" which you drag into your Browser-Bar ?

Anyway, it is just an idea which came to my mind..... not to facilitate the "Browser Bar", but to build it right into the Editor.


Maybe it would work without even having a Button in the Editor ? Just having the capability build into the Editor, so that the Editor pulls the image via "Drag & Drop" and displays the image and the image-URL.
And getting rid of the long image-code (I guess this is called "URI-code") ?

:coffee:
 
The bookmarklets you speak of are built outside of a page realm and the browser executes them using the current tab.

The current drag and drop implementation does attempt to pull in the URLs for images.
 
The bookmarklets you speak of are built outside of a page realm and the browser executes them using the current tab.

The current drag and drop implementation does attempt to pull in the URLs for images.


yeah.....

if you find a solution to "combine" those 2 features into 1 feature...... then I will call you "King" until the end of my lifetime.

;)
 
I personally don't think the current implementation is incomplete or that a bookmarklet type button would be worth the hassle knowing all the barriers. And you can call me Jeremy, King isn't necessary. lol
 

Similar threads

Back
Top Bottom