FC Print button and CSS switcher ?

More
4 years 1 month ago - 4 years 1 month ago #81925 by bendeb
Hello,
I want to allow users to change CSS in a specific FC template with some buttons like this :
Code:
<link id="css" rel="stylesheet" type="text/css" href="/components/com_flexicontent/templates/my_template/css/category.css"/> <button onclick="document.getElementById('css').href='/components/com_flexicontent/templates/my_template/css/light.css';">Light</button> <button onclick="document.getElementById('css').href='/components/com_flexicontent/templates/my_template/css/other.css';">Other</button> <button onclick="document.getElementById('css').href='/components/com_flexicontent/templates/my_template/css/category.css';">Default</button>

Buttons to change CSS works good, but when I click on Print (FC Print button), browser only load Default CSS and not the current CSS user have choosen.
Is there a way to load choosen CSS when I click on Print button ?

Thank for your answer.

Regards.

Flexicontent 4.1.0b1
Joomla 3.9.18
Last edit: 4 years 1 month ago by bendeb.

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

More
4 years 1 month ago #81926 by micker
difficiult to reply but i think you need to a print query in your css not ?
did you a link for ?

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

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

More
4 years 4 weeks ago #81929 by bendeb
Thank for your answer.
Media queries Print doesn't work for this because user can't select the CSS he wants to print.

I have a default css and a css switcher to load a different CSS, but when I click on Print button, only the default css is loaded, even if the user have choosen the different css.

Flexicontent 4.1.0b1
Joomla 3.9.18

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

More
4 years 4 weeks ago #81930 by micker
I think print button use component view without custom loading and css ... Create your own button for your own view

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

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

More
4 years 4 weeks ago #81931 by bendeb
Yes but if I knew how to do it, I wouldn't have come here asking for help.

Flexicontent 4.1.0b1
Joomla 3.9.18

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

More
4 years 4 weeks ago #81932 by micker
Hi as i Say a like to view problem Can be cool

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

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

More
4 years 4 weeks ago #81933 by bendeb
I have send you a PM.
Thank you.

Flexicontent 4.1.0b1
Joomla 3.9.18

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

More
4 years 4 weeks ago #81934 by micker
tu n'as pas besoins de créer tes boutons comme ceci, tu peus créer 3 template items differents et ensuite permettre au personnes de choisir leur templates
regarde ici : flexidemo.com3elles.com/demoj4/immobilie...-toulouse/house.html au niveau des chiffre de page
tu peus changer de layout et donc garder le bon css lier
c'est dans les categorie que tu peus activer ou non le layout switcher et décider quel layout est disponible

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

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

More
4 years 4 weeks ago #81935 by bendeb
En fait, sur le lien que je t'ai envoyé, tu as déjà un sélecteur de mise en page (vue table par défaut, et une vue que j'ai faite).
La vue que j'ai faite est bien un template Flexicontent.
Ce que j'aimerai, c'est qu'au lieu de créer plusieurs templates pour afficher le contenu différemment (alors que la structure html est la même), j'ai juste un seul fichier css à charger, d'où ma fonction.
Le but d'une de ces feuilles de style différentes est de faire une version allégée en couleur et en noir pour l'impression.

C'est contraignant de créer un template, d'affecter tous les champs nécessaires, de faire les réglages et d'éditer les différents fichier php, alors que seul le css change.

Flexicontent 4.1.0b1
Joomla 3.9.18

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

More
4 years 4 weeks ago #81937 by micker
ton soucis est complexe car en fait il n'est pas lier a flexi mais a ton theme
flexi n'inclus pas de css dedier au print, pour afficher le print il utilise la vue component de joomla (sans menu ni module) avec les css au minimum et les css de print de ton template
il te faut soit overrider la vue component pour charger tes css en plus soit voir coté template de ton joomla

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

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

Moderators: vistamediajoomlacornerggppdk
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