How can I do a Directory Listing of ebsites with Ez? - ezpublish

I need to do a specific task with Ez Publish but I don't have a clue on how to do it.
What I need to do is a list of Websites(Website directory). I will need to add basically two kinds of data:
Website Name
URL of the website
Then, when I click in the website link it will redirect to a page where I have the IFRAME with the link(URL of the website).
Can someone give me a clue about how to do this with Ez Publish? I'm a beginner.
Best Regards,

You haven't said anything about where you're getting the list from, so I assume you have the list already and just want to know the correct way to input this type of content.
Login to the site admin area, browse to the part of the site you want the list to be at (usually a folder). You'll be adding content items of type 'link' below the folder.
Select the 'Link' content type and click on the 'Create' here button. Enter the content (including the link URL to the page containing the IFRAME) then send for publishing.
I'm assuming the sites are your own, since many sites now take steps to prevent others placing their page in an IFRAME.
If you want this page to not just link to the iframe page, but to actually display the iframe content, then you'll need to override the default link template (copy it and tell eZ to use your version instead) and add a bit of html for the IFRAME.
If you're the main user imputing this content, you could also just allow eZ to accept literal HTML in the main description text areas (XML Block) and just paste in your IFRAME html. Ugly but quick to set-up.
You should be able to find many examples of entering literal html at the community web forums http://share.ez.no/forums

You should create a specific class for that with the two fields you need.
One for the name and another one with the URL.
Then you'll just have to make an override of node/view/full.tpl for your new class Where you will display the name and an iframe with URL that have been typped in your class instance.

Related

Ajax feedback from newsletter

I have created email contents as an html page.
I have placed 4 check boxes and every time one of them is checked I want to run ajax which calls a url with parameters. Is such a thing possible or the email client will not run it for security reasons or/and other reasons?
I can do it with a link to a page with the same contents but the recipient may not bother to click the link.
The whole idea is: Can we run ajax calls in html email contents as if the contents were in an autonomous web page?
No you can't. All JavaScript is stripped from emails for security reasons. The best you can do, as you've listed, is to have a link in the email with parameters to allow the landing page to do it.
You can achieve interactivity, however, with checkboxes - such as hiding/showing content (already placed in emails). If you're already inserting the parameters, I'm assuming then you have the information--so place that content hidden in the email, which when checked, shows. Mark Robbins shows how it's done: https://www.webdesignerdepot.com/2015/10/punched-card-coding-the-secret-of-interactive-email/ (if that's what you wanted, let us know in the comments and/or include your code and we can give a tailored example)

Create a Link To An External Page On Order Confirmation Page in Prestashop

I'm very naive. I am not able to create an external hyperlink on the order confirmation page. (lets say http://google.com)
I've modified the bank transfer module to create a manual payment method, but I am not able to add a simple link on the confirmation page. The screenshot depicts it well.
Also attaching the screenshot of the backend where I input the text. I've tried editing the tpl files, but it doesn't change the actual code on the browser. I have even tried disabling html filter and typing href on the text box itself, again the code just disappears in the browser.
The images will make things very clear.
Thanks.
Link
Backend
The solution is simple, like ébewè said, go to advanced settings > Performances, and clear cache or select no from the drop-down menu next to cache.
Then you can just use high school grade html commands in tpl file to wrap the requisite text inside the code. It works!
Thanks ébewè!

Facebook feed dialog deprecating custom fields

Facebook Feed Dialog 2.9 has deprecated the custom fields (name, caption, picture, description) - https://developers.facebook.com/docs/sharing/reference/feed-dialog.
I'm working on an AJAX site where all content and metadata is loaded dynamically. If I just use the link property, the metadata isn't set on initial retrieval of the page so the post doesn't contain the right content.
How can I share an AJAX page on Facebook without having to go down the route of prerendering static pages server side? Thanks
If you can program your page to populate the appropriate metatags on the page load based off of a variable http:/yoursite.com/yourpage.php?thisversion=1 then when you want to share version 1 of the page, you just share the URL with the appropriate variable to populate it. You can still remain on your current version of the page but when you share the URL that would prompt that specific version, facebook makes a call to that respective URL and pulls the appropriate metatags that would be populated by your variable without having to reload the page your are currently displaying. Sorry I don't have time at the moment but will try and comeback and add some sample code for clarity.

Can bookmarket modify original page?

I have a bookmarklet that opens a dialog (in reality an iframe) and extracts some information. When the dialog is dismissed I want to put that information into edit text fields on the original page in the browser (like the way LastPass will automatically fill-in login forms on a page).
Is this possible? I'm thinking that same-origin-policy will prevent this, but maybe there is a way (without installing extensions such as greasemonkey, etc).
Edit: to be more precise: the bookmarklet appends a DIV to the original page; that DIV contains an IFRAME that loads my page; this page fetches some information; once this information is fetched within the IFRAME I want to remove the DIV and (somehow) put that information into the original page.
The issue I face is communicating the information in the IFRAME back to the original page.
What you are looking for are the functions addEventListener and postMessage.
Relevant links:
http://caniuse.com/#feat=x-doc-messaging
How do you use window.postMessage across domains?

Ajax generated pages with different URLs

I couldn't really word the title very well, but here's my problem: I've got a webpage that reads from a database each time the user clicks a button, the content is then replaced for part of the page.
Because it is an ajax load, everything is done in the background, and so the URL stays the same. This wasn't be a problem at all until I realised that I will want to have a different Facebook comments box for each set of content that is loaded - so if someone comments, it is posted to their facebook profile, people click on the link and are then taken to different content.
So... what I need is some way of referencing each set of content, and I've found a site that does exactly that (I'm sure there are a lot of them).
Here's the link.
Each set of content has a different 'hash code' (because I don't know the actual name for it) which is appended to the URL - in this case the code is "#1922934", this allows people to post links to it that specific set of content on Facebook etc. - and also allows a different Facebook comment box for each set of content.
Does anyone know how such a set-up can be achieved or how these 'hash codes' work?
Here's a document from wikipedia on it.
[http://en.wikipedia.org/wiki/Fragment_identifier][1]
The main idea is that URI fragments are used because they don't cause a page reload. They also can be used to refer to anchors on a web page.
What I would do is on page load use JavaScript to read the URI fragment (location.hash) then make a request to your server to load the comments etc. The URI fragment cannot be read by a server and is only found through a client (browser)
Sounds like you want something like SammyJS.

Resources