Custom data in pyro cms pages, such as images or other data - pyrocms

I'm wondering how in PyroCMS I can add a custom field to a page. Ideally I would like to have an image area at the top of the layout, and have a custom field in pyro that would allow someone to populate that image from the pages module. I realize that there are some image plugins that allow me to attach images to pages, but I would like to be able to add the images directly into the page in the admin (as well as other custom fields for the pages). Even on a separate tab would be fine with me. I'm fine building something if someone can point me in the right direction.

Currently if you want to add a custom field to a page you have to hack the module. This is obviously not ideal and im not really suggesting it, but I had to do it for http://tedco.org/business to add a "Subtitle" field to each page.
2.2/develop is having its Pages and Blogs moved over to Streams, so you can add custom fields to all pages globally, meaning you can add an image in if you like, or append a US State for some reason, or add a slider. Whipee!
So right now: Hack it or wait. 2.2/develop will have your feature in a week or two.

I'm not sure you can do this directly from the pages module yet or not without some customization (possible hacking) though, I just asked and will update if possible.
In the meantime this might be helpful:
Consider looking into PyroStreams. for this though, it will require the Pro version of PyroCMS or you can purchase it from Parse19 directly.
You might find this article helpful about organization and page layouts.
Here is an article called Dynamic Pages with PyroCMS and PyroStreams though, it's a bit outdated now.
You may also make use of the gallery module, which is free though, I'm not sure this will meet your needs.

Related

Liferay 7: Is it possible to get an image for from a linked site to a sitemap automatically?

Liferay 7.3.2.
I'm using a sitemap to create link boxes that link to other pages in the website. Links and names and all else is basic stuff, but I have no idea, if and how I could get images for the boxes.
Asset publisher would've been my first choice, as I've done similar stuff before with them, but I can't find a way to add pages to the publisher, so I'm not sure if it's viable here. Of course, I could create an asset publisher that would ask for a name, image and a link, but this should be automatic to avoid extra hassle.
Sitemap allows for automation, if you just map the page correctly, but getting the image would still be a problem.
Navigation menu I haven't really put much thought into, as there will be many pages with link boxes and would be really hard to control. The image would be a problem as well.
The optimal solution would be to get the image from the page the link takes the user to, but if that's impossible, I wonder if there's a way to give webpage an image, that could be shown here.
Got it working with a bit of looking around! This can help with same kind of problems others might be facing, so I'll gladly answer this myself!
From Admin panel, go to Settings and Additional Fields
Select Page and add a field to it. After filling the details, you should be able to see this field in the page settings for every page.
Go to page settings and fill out your info. In my case, I created a text field, that will be used for image URLs.
Finally, in your Application Display Template, you can find the field by writing:
${entry.getExpandoBridge().getAttribute("Extra field")}, Extra Field being the name of your field. Remember to put conditional statements, if necessary!

Joomla - Modifying default category list view (through overrides?)

I'm building a site for a friend and I should state that this is not what I'm doing for living. I just started working with Joomla a few days ago.
Everything is good so far, except I'm stuck at one point.
This is a site for a construction company and I need to create articles for on-going and completed projects. I will create an article for each project and each article will belong to a category, 'Completed' and 'On-Going', respectfully.
I plan to create menu links for 'Completed' and 'On-Going' categories in main menu. I also want to present a thumbnail of the article on the category list. Problem is, standard look of the category list is kinda ugly, and I have no idea how to change it. I'm using a template named PixelDot, but it does not seem to do any good for my problem.
During my research, I stumbled upon concepts 'Layout Overrides' and 'Alternative Layouts'. I have basic html and css knowledge, also some PHP, but I am totally lost on which file(s) to modify. I also need a little help on get the entry text picture as a thumbnail on the category list (this is the list where you see 'articles' aka projects which belongs to the category (completed or on-going), when you clicked on relevant menu button)
Any help will be highly appreciated. My Joomla version is 3.4.1. (which I believe most up-to-date version as today)
I'm sometimes making it more complex while I try to make things detailed and clear, I hope this is not one of those cases.
First, I would suggest using tags rather than categories to manage this. Tags are much better suited for temporary labelling or dividing into groups.
Second, go to the template manager, template view for your template.
Go to the create over ride tab and select the view that you want to override (i.e. tagged items).
This will automatically copy all the files to the correct location in your template.
At that point you can play around with the layouts to your heart's content.
Also ... some pieces of the layout you may want to override may not be in the traditional layout but may be in a jlayout. You can do the same thing with them. THis is all documented in the docs.joomla.org site as well as around the web.
I also would do this with Tags. One reason is, assuming you are using SEF URLS, that the projects article pages will have a unique URL. If you move a project's article from "on-going" to "completed" then you may be changing that SEF url. This will cause your search engine ranking for that page to be lost.
I would tag each article "on-going", "completed", etc and then create a menu item to display only that specific tag. The project's article would stay in its original category, that could be my project type, project location, etc; which also will increase the SEO for that given project's article.

How to create a single page vertical scrolling site in Joomla

I can create a standard Joomla template in my sleep, but recently I had a client come to me who wants a vertically scrolling, single page site. I whipped up an HTML/CSS mockup that functions beautifully but I have a question re: converting it to a Joomla template:
Do I just create a single article in Joomla that contains all of the content for the single page, and then create menu items that link to the section divs?
Many thanks,
Cynthia
yes I think that good , also you can make all items in "index.php" in template folder and make menu items link to divs by "#" plus ID .
you can add all items you want as module and you can use component in modules plugin lik :
http://extensions.joomla.org/extensions/core-enhancements/coding-a-scripts-integration/embed-a-include/18121
Hope that help you
You'd be better to insert the content via creating a bespoke module or component - putting code in the WYSIWYG area kind of defeats the point of using a CMS at all - someone with no coding skills has to be able to update the site and not accidentally delete the layout.
I'd perhaps question why it needs it to be in Joomla at all, though. It doesn't sound like it will be benefiting from many of its features.

Making a different type of home page in Orchard

I've just started with the Orchard CMS and I can see that I can create a page and have different widgets on them, but I need the homepage to have a different layout.
I'd like to have some sort of different cshtml file for the homepage, but I can't seem to work out how to do it from the documentation. I also need to have four text areas on the home page that aren't on the main page.
Can someone who has done this point me in the right direction?
You should use designer tools module if you are using Orchard 1.1 +. Just search for Shapes in the admin and install the tools. Then you can create Alternates by reviewing the shapes in-browser.
In your case you should be able to create a view with the name: Content-url-homepage.cshtml
This may help you, it's a post I found about making your own themes and is a fairly simple example but covers what you are looking for:
http://www.nogginbox.co.uk/blog/theming-orchard
/Views/Content-11.cshtml
I wanted to display the content on my
homepage slightly differently than
other pages. My homepage has an ID of
11 so I was able to reference it with
a file called Content-11.cshtml. I
could also have created a template for
all blog post content using a file
called Content-BlogPost.cshtml had I
needed to do so.
You can try this to vary the homepage layout: http://weblogs.asp.net/bleroy/archive/2010/12/14/switching-the-layout-in-orchard-cms.aspx
Orchard 1.1 will also give you a homepage alternate out of the box.

display custom attributes on Virtuemart browse page

I need the browse page to show quantity box, custom attributes, and Add to Cart button all together.
It doesn't show it at all. Only when you go to the product page, you can see them.
Any solutions?
Thanks, Ahmed.
Ahmed, you'll have to modify the template directly to do something like that. VM uses a large number of template files written in PHP. If you're using the default template, you can find them here:
components/com_virtuemart/themes/default/templates/
From there, it takes a little looking around to figure out exactly which template you need to edit. If you need to edit a browse template, my recommendation is go to your VirtueMart Administration in Joomla backend and look at Admin | Configuration | Site | Layout to get an idea of which files you're using. It will probably say "Default" in the dropdown, with a Configuration link directly below. Click that link and look at the very first item, Product List Style. From the description of your layout desires, you might be using Flat Product List.
The main file for editing that layout is:
components/com_virtuemart/themes/default/templates/browse/includes/browse_listtable.tpl.php
If you're a programmer, you should be able to look thru the code and correctly guess which code elements are being used to display VM product details. If you're not a programmer, you can still fake it by commenting out sections to see what "goes away" on the actual product page. Use what you learn to strip out useful code and move it around.
Another useful file to pull VM product code from is:
components/com_virtuemart/themes/default/templates/product_details/flypage.tpl.php
This is the actual product view (unless it's been changed in VM config), and contains pretty much all the common code elements that extract product details. You should be able to lift some of that code and place it where it needs to go in other forms.
Good luck with all of this. I find VM coding painful, and community support in the VM forums can be... sparse...

Resources