[SOLVED] Improvements for append / prepend sitename to page title

More
9 years 11 months ago - 9 years 11 months ago #54154 by pipedream
While developing some improvements for the page title, which were submitted in this PR github.com/FLEXIcontent/flexicontent-cck/pull/198 I noticed that when the category title is added to the item title, by enabling the respective option, the category name is not translated.

As a solution, I guess it would be great to have $globalcats translated, which would also make things easier to template, rather than having to use the code you suggested here:
www.flexicontent.org/forum/21-troublesho....html?start=10#52309

That way, we wouldn't need to use SQL code in the view/template part.
Last edit: 9 years 11 months ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
9 years 11 months ago - 9 years 11 months ago #54155 by ggppdk
Hello

$globalcats was meant to get
- category tree information
e.g. creating the category selectors
e.g. creating lighter SQL queries
by
- avoiding extra joins with the categories table and with our multi-categories assignments table
- avoiding re-executing some PHP code too,

The 'badcats' join in joomla is quite expensive in large websites (50,000 items) even if you only have 10 categories

-- the usage of it to get category title (in frontend views) is rather a misuse of it,

and getting the category title with the he SQL query will cost almost nothing in both item and category view, because the categories table is already joined

we have a bug issue about this already open:
github.com/FLEXIcontent/flexicontent-cck/issues/129

it had milestone v3.1, by changed it to have milestone v3.0

will update code so that falang translate will work

thanks for pull request


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...
Last edit: 9 years 11 months ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
9 years 11 months ago - 9 years 11 months ago #54160 by ggppdk
Hello

accepted merge request
and fixed issue with prepended category title no translated
(please go ahead and test)

about making pull requests, we have less strict code styling than Joomla, but please note that
- code is padding line starts with TABs instead of spaces (set your editor to use TABs and (2 spaces = 1TAB))
- avoid making 1 commit per file, if you change many files it is ok to more than, just add all changed files and then commit

thanks for contribution


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...
Last edit: 9 years 11 months ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
9 years 11 months ago - 9 years 11 months ago #54162 by pipedream
Sorry for the tabs, I was working with vi in Linux environment and wasn't aware that the tabs were transformed into spaces when copying.

I'm not very familiar with GitHub, which i only use online.
I started by creating a Fork and changed the first file.
I only have 2 options: commit or create a new branch.
Maybe you can explain me better the workflow... :blush:

Also, how can I download the last version in GitHub ready to install in Joomla?
Last edit: 9 years 11 months ago by pipedream.

Please Log in or Create an account to join the conversation.

More
9 years 11 months ago #54214 by ggppdk

Also, how can I download the last version in GitHub ready to install in Joomla?

Hello

you can install the environment of your choice,

when you get more time, you can invest it on reading some Git and/or GitHub tutorials


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.415 seconds
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline
Save