Item title before category title with sh404sef?

More
12 years 1 month ago #43724 by victorio404
I am calling RSform when i'm in Flexicontent item.

Here is a button called "Request a callback":
www.ultracruises.co.uk/Offers/US ... -Tour.html

Your code is returning the title perfectly if I load the form with the content plugin inside the Flexicontent item, but not when i call the form in popup box. I just want to show the form after a button is pressed in popup - that is the problem :)

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

More
12 years 1 month ago #43739 by ggppdk
Hello

sorry i do not understand, this an RSform and not a FLEXIcontent item form, please explain why it is related to FLEXIcontent ,

e.g. relation:

you have a item URL in it, that is stored in hidden form field and ... ...


-- 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 review. Thanks!

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

More
12 years 1 month ago #43744 by victorio404
Hello,

I have a Flexicontent item + Rsform.

In a hidden field of Rsform i'm trying to capture and send the flexicontent item title using your code:
Code:
$db = & JFactory::getDBO(); $fcitem_id= JRequest::getInt('id',0); $fccat_id= JRequest::getInt('cid',0); $view= JRequest::getVar('view'); if ($view!='items' && $view!='article') { return "not in items view"; } if ($fcitem_id) { $query = 'SELECT c.* ' .'FROM #__content AS c ' .'WHERE c.id = ' . $fcitem_id; $db->setQuery($query); $itemdata = $db->loadObject(); $item_title = $itemdata->title; } if ($fccat_id) { $query = 'SELECT c.* ' .'FROM #__categories AS c ' .'WHERE c.id = ' . $fccat_id; $db->setQuery($query); $catdata = $db->loadObject(); $cat_title = $catdata->title; } return $item_title." - ".$cat_title;
This code works(sends the item title) if the form is loaded using the Rsform content plugin - withing the flexi item.

The problem is, I want to call the rsform in a popup instead.
My question is: is it possible to capture the Flexicontent Item Title in a hidden field of Rsform when the Rsform is being loaded in a popup(not in flexicontent item template)?

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

More
12 years 1 month ago #43769 by ggppdk
Hello

the popup is inside an IFRAME with a different URL, so you no longer have access to:
FLEXIcontent item id and and category id
via looking into the URL


I think it maybe possible to use
$_SERVER["HTTP_REFERER"]
and find FLEXIcontent item id and and category id from there

but parsing the refer URL is a Joomla SEF URL,

and Joomla router must be called to analyze it, i have never done this, but it should be possible


-- 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 review. Thanks!

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

More
12 years 3 weeks ago #44012 by victorio404
Thanks,
$_SERVER["HTTP_REFERER"] works for calling referrer link, but if there is a validation error on the form it sends the popup link instead of flexi link.
I think I'll just ditch the popup :)

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