Redirecting in a onepage - html

So I'm working with wordpress and a costumer wants a one-page site. Now we have it working and all but if we go to www.examplesite.com/contact it should redirect to the onepage # contact. My collegue and I can't get it working so I thought lets ask here.
Please help

I'm assuming this is linked to a DB which selects what data is shown on this one page layout?
You would need to create a variable that is used to select the data you wish to see and use the POST[] method in the page when clicking on 'Contact' to change the variable to contact which would load the Contact Page up.

Related

How to make a back button that goes to the parent page in C# Razor and 2sxc App?

I have a 2sxc app that is a simple parent-and-child setup. So there's a listing of cards and each card has a details view. I use this app on 6 pages - each with their own unique content. I want to make a "back" link inside of the details view that goes back to that detail's parent.
So one of the pages is called "Motivate", and I want it so if a user goes to "Motivate" and then clicks on one of the details views, let's say "motivate/details/marketer", I want a back link on that details view that goes back to the "Motivate" page. But this link would have to work for each of the 6 categories dynamically. How would I create this in c# razor?
Can you post your code just so that I can see how its all done?
You can the current page id in 2sxc using "#Dnn.Tab.TabID"
If you can get the parent page ID you can use the following link to go to that page
"http://www.example.com/Default.aspx?tabid=TABID"
Regards
Kieran
I was overthinking this. Here's my code:
Go back
This works because when I'm on the details view (a different template), the landing page is still the Tab's Full URL.

Show a particular DIV from a previously viewed page

I'm not sure if this is possible (I'm not a coder!) but here goes anyway...
The DIV class for the product name on the following page is "productTitle"
https://www.ultimadisplays.co.uk/Alcohol_Hand_Sanitiser_Gel/?categoryId=2147499177&tab=0&subTab=1
I won't bore you with why but the website is very old and limited however we can put a button on each product page which can link to a form. This form is on a completely separate hosted platform.
Is it therefore possible to take the product name over to the new page with the form on it using the DIV class so that when the form is submitted we will know what product they are interested in rather than they have to write it into the form manually?
Thanks in advance!
You can send whatever data you want between different sites or platforms by sending it in GET or POST request either by refreshing page directly or by using AJAX.
I don't think it's a good option just for a form. But you have this possibility nevertheless.

squarespace query only for home page

I am using squarespace developer kit and going well. I am wanting to integrate some queries to display some very simple data form my blogs that will appear on my home page ONLY.
Not being very fluent in JSON, I am struggling to implement the query on the home page. I have it set up to display the data from the selected blog but it displays the data through each page.
I only want the data to be visible on the home page at the top. Not in the header but inside where all the content is.
Here is my query that works perfectly well
<squarespace:query collection="feature-articles" limit="10">
<li>
{.repeated section items}
<li>{title}</li>
{.end}
</li>
</squarespace:query>
Can the data be inserted into a code block via the content manager so I can then insert into within the content or am I totally wrong in thinking that.
What I will then do is style/ add or edit the UI of the data into either a carousel or whatever is needed for the project.
I just need to know where to store the query so that it fits in with the content.
Appreciate any time.
Review the following link to see how you can edit a template file, to make different pages use different templates.
http://developers.squarespace.com/template-configuration/
Make a completely custom template just for your homepage then paste you code within your custom .region file as outlin ed in the above guide.
Here is the page about working with template pages:
http://developers.squarespace.com/layouts-regions/
Seeing as you know about , I have a feeling you might already know this, so you might want to be a bit more specific about how your displaying your code and I will gladly update my answer.

Liking - Aggregating One Number For All Pages

I have Facebook Likes buttons on every page of my website. I want it so that when a user Likes, there will be a Like pointing to the current page they are on. But the number will reflect how many Likes for the entire page. I am wondering if this is possible?
From my understanding, the number of Likes is associated with the link the user is liking. Is my understanding correct?
Facebook like buttons are linked to a URL - either that of your website home:
www.example.com
OR separately a single page
www.example.com/post-about-example
When you create the like button you decide what the like is against - essentially if you are selecting the home page - it is still only liking a single page, but its just the main page you want the facebook profile to link to. You need to have each button liking EITHER your home OR your individual page - one button cannot do both.
On a side note - from an SEO standpoint, it is better if your likes are associated with your home page as this should link to your most important pages first - reaping the best SEO benefit for the more important pages - whilst also directing users to what is set up as a landing page.
If your site is one which relies on multiple posts, say a blog. It may be better to go down the path whereby each post url has its own facebook like button FOR THAT URL. This way each post gets more exposure.
I hope that answers your question.

I want to have a link to my facebook page from my blog

Every time I try to embed code that was recommended by another user, I get the same message: Could not retrieve id for the specified page. Please verify correct href was passed in.
All I want is something on my page that a reader can click to take them to my Facebook page. What am I doing wrong?
You can create a personal username for your account on facebook, check Facebook Usernames general information, creating a username will provide you with a custom url something like
www.facebook.com/YOURUSERNAMEHERE
you can easily add this to your blog by using the following html
Follow me on facebook
It would also be helpful if you post the code that you're trying to use currently, otherwise no one has any idea what you're trying to do.
If you just want a link in HTML to your facebook page, put this into your page:
My Facebook Page
The section that goes within the quotes should be the URL you see when you navigate to your Facebook page.
Are you talking about a Page or Profile?
For Pages, the Like Box plugin is probably the best option, and lets people like the Page right from your website: https://developers.facebook.com/docs/reference/plugins/like-box/
For your own Profile, there's Badges ( https://www.facebook.com/badges/ ) which you can use
If it's your own Profile and you want people to Subscribe to you ('Follow') - there's a subscribe button you can use for this: https://developers.facebook.com/docs/reference/plugins/subscribe/
i dont know why, but for some reason, you have to include the http:// before the link