CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Joomla! Installations (Moderator: Deepak Srivastava) »
  • Duplicate menu ids
Pages: [1]

Author Topic: Duplicate menu ids  (Read 6889 times)

david@emediacy.net

  • Guest
Duplicate menu ids
April 30, 2008, 07:20:36 pm
I have installed civicrm 2.0.2. I have profiles and donation pages set up. The contact form menu item CID is 78. When i attempt to add the donation form, it also has the CID 78. I changed the the task and contribution id but it still displays the contact form instead of the donation form. Any Ideas? I have used several previous versions of civicrm. This was never a problem before.

Also, I recently changed to hostgator because they run php5 and mysql 5. Now i see that there will be database incompatibilities with myISAM.

This form host gator:
InnoDB databases are still available on some of our older or original server setups where we did not disable InnoDB, you *may* be able to talk to sales about getting you moved to an InnoDB capable server. Keep in mind, that InnoDB storage engine is *MUCH* more likely to have data corruption than MyISAM so your database(s), which is why we no longer support InnoDB

How much of a problem is this likely to be if I remain myiSAM

Thank You,
David Buchmueller

lcdweb

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1620
  • Karma: 116
    • www.lcdservices.biz
  • CiviCRM version: many versions...
  • CMS version: Joomla/Drupal
  • MySQL version: 5.1+
  • PHP version: 5.2+
Re: Duplicate menu ids
April 30, 2008, 08:26:05 pm
Make sure you're putting the ID number in the correct box in the Joomla menu creation screen. There's a box for contrib/event ids, and a separate text field for profile ids. If your contact form is JUST a profile, it could potentially have the same ID as your donation form (contrib page) -- but the id number goes in different text fields in the menu form.

Re: InnoDB vs. MyISAM

I don't know why host gator is saying that InnoDB is more likely to have data corruption. I think it's safe to say that they're just plain wrong.

There's a bunch of differences between the two engines. MyISAM uses table locking for updates, whereas InnoDB uses row locking. Consequently, MyISAM is *generally* better for high read-load applications, and InnoDB for high update-load applications. InnoDB supports transactions and foreign key constraints, which I understand are some of the main reasons why it was used for CiviCRM over MyISAM.

I *think* (and I'm no expert), that in general InnoDB is considered a more reliable engine over MyISAM when it comes to data integrity (it also has recovery options, whereas MyISAM does not).

See also this: http://dev.mysql.com/doc/refman/5.0/en/innodb-overview.html

I suspect that CiviCRM won't even run with MyISAM tables, because of the transactions and foreign key constraint usage. If it does run, you are likely compromising the integrity of your data, so I wouldn't recommend it.

-Brian
support CiviCRM through 'make it happen' initiatives!
http://civicrm.org/mih

david@emediacy.net

  • Guest
Re: Duplicate menu ids
April 30, 2008, 09:34:29 pm
Thanks for the quick response.

Here is what i am seeing for the contact form.

Choose CiviCRM task    Profile Create
Contribution or Event id    Not filled in
Profile id    1
Reset     1
Joomla CID   78

For the contribution form:

Choose CiviCRM task    Online contribution
Contribution or Event id    1
Profile id    not filled in
Reset     1
Joomla CID   78

CID is the joomla content ID, I believe.

All of this was working in 1.8. Maybe I will go back to that.

I guess i will see if I can get php5 mysql5 and innoDB going. Thought I was good.

Thank you,
David

lcdweb

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1620
  • Karma: 116
    • www.lcdservices.biz
  • CiviCRM version: many versions...
  • CMS version: Joomla/Drupal
  • MySQL version: 5.1+
  • PHP version: 5.2+
Re: Duplicate menu ids
April 30, 2008, 10:01:27 pm
Hmmm...
You have a fifth field on the menu parameters area that says "Joomla CID"? That's weird.

I just looked at both a J1.5 and J1.0 installation with CiviCRM 2.0 and there are only the four parameter fields for the menu creation -- task, contrib/event id, profile id, and reset. I really don't know where that fifth parameter is coming from.

Do you have any "system-wide" extensions setup in your Joomla install? Like one of the SEF extensions, or an ACL extension? I'm thinking maybe they create that field to control access or link re-writing. I'm pretty sure that field is not created by CiviCRM.
support CiviCRM through 'make it happen' initiatives!
http://civicrm.org/mih

lcdweb

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1620
  • Karma: 116
    • www.lcdservices.biz
  • CiviCRM version: many versions...
  • CMS version: Joomla/Drupal
  • MySQL version: 5.1+
  • PHP version: 5.2+
Re: Duplicate menu ids
April 30, 2008, 10:08:28 pm
I just did a quick search of the CiviCRM code and also a google search for "Joomla CID" -- nothing. Haven't the faintest idea where that's coming from.

Just for kicks, try leaving it blank and test your two forms.
support CiviCRM through 'make it happen' initiatives!
http://civicrm.org/mih

david@emediacy.net

  • Guest
Re: Duplicate menu ids
May 01, 2008, 08:23:00 am
I could have been clearer about what is going on. I will attach a screenshot. Each menu item needs a unique content ID. The image shows two of number 78

lcdweb

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1620
  • Karma: 116
    • www.lcdservices.biz
  • CiviCRM version: many versions...
  • CMS version: Joomla/Drupal
  • MySQL version: 5.1+
  • PHP version: 5.2+
Re: Duplicate menu ids
May 01, 2008, 08:50:58 am
Ahh...
CID in Joomla is Component ID, not content ID. Both of those menu items use the same component (CiviCRM) which is why the CID is the same (and not the issue). In Joomla menus, it's the ItemId that must be unique and is used to identify parameters specific to the menu item.

So eliminate the Joomla CID from the discussion. Make sure your parameter settings for each menu item are correct. You said that they are both landing on the same page (contact form)? Some troubleshooting ideas.

1) Unpublish the contact form and then try accessing the donation page (since that's the one with the problem). Also, I note that on  your screenshot your donation page is not published. (Perhaps just a result of your testing process)

2) Go back into your contrib page settings and make sure it's enabled and that the config related to the online page are setup correctly.

3) Provide the url to the donation page. I want to see what string is built for clues.

-Brian
support CiviCRM through 'make it happen' initiatives!
http://civicrm.org/mih

david@emediacy.net

  • Guest
Re: Duplicate menu ids
May 02, 2008, 08:06:23 am
Thanks for your help. It turned out that an sef component was changing the urls. Should have caught it.

lcdweb

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1620
  • Karma: 116
    • www.lcdservices.biz
  • CiviCRM version: many versions...
  • CMS version: Joomla/Drupal
  • MySQL version: 5.1+
  • PHP version: 5.2+
Re: Duplicate menu ids
May 02, 2008, 09:09:01 am
Yeah, I should have mentioned something specific to that. I've noticed that the builtin SEF in J1.5 can break some of the CiviCRM menu links. I think there's some way to have SEF shut off for a specific component. It would be useful to track that down, as there are still a lot of components that don't jive with SEF yet. I'd rather be able to turn SEF on and just eliminate a few components, than have it completely shut off.
support CiviCRM through 'make it happen' initiatives!
http://civicrm.org/mih

david@emediacy.net

  • Guest
Re: Duplicate menu ids
May 02, 2008, 09:29:20 am
I use the Artio JoomSEF component. It is fairly complicated but works great. I mostly just enable it. In this case, I told it not to rewrite the civicrm component links. Once i have civicrm working the way i want, i will add custom urls.

I am however running civicrm without innoDB at the moment. Very happy with the host. I am waiting to hear if they will enable innoDB. I looked in the forum for joomla hosting and found nothing. I did find a mention of drupal value hosting. Have you heard anything about them?

mcsmom

  • I post frequently
  • ***
  • Posts: 266
  • Karma: 23
    • Official Joomla! Book
  • CiviCRM version: 4 and 3.4
  • CMS version: Joomla!
Re: Duplicate menu ids
May 02, 2008, 12:45:46 pm
What really needs to happen is to build a router for civicrm.

Donald Lobo

  • Administrator
  • I’m (like) Lobo ;)
  • *****
  • Posts: 15963
  • Karma: 470
    • CiviCRM site
  • CiviCRM version: 4.2+
  • CMS version: Drupal 7, Joomla 2.5+
  • MySQL version: 5.5.x
  • PHP version: 5.4.x
Re: Duplicate menu ids
May 02, 2008, 01:04:07 pm

wanna expand on this a bit?

Note that in 2.1 our menu system is completely db driven, i.e. all the information to execute any civicrm url is stored in the database

lobo
A new CiviCRM Q&A resource needs YOUR help to get started. Visit our StackExchange proposed site, sign up and vote on 5 questions

lcdweb

  • Forum Godess / God
  • I live on this forum
  • *****
  • Posts: 1620
  • Karma: 116
    • www.lcdservices.biz
  • CiviCRM version: many versions...
  • CMS version: Joomla/Drupal
  • MySQL version: 5.1+
  • PHP version: 5.2+
Re: Duplicate menu ids
May 02, 2008, 04:38:01 pm
If you are looking for cheap shared hosting, I've had pretty good success with Bluehost.com.
You can't run CiviMail bounce processing though.
support CiviCRM through 'make it happen' initiatives!
http://civicrm.org/mih

mcsmom

  • I post frequently
  • ***
  • Posts: 266
  • Karma: 23
    • Official Joomla! Book
  • CiviCRM version: 4 and 3.4
  • CMS version: Joomla!
Re: Duplicate menu ids
May 03, 2008, 05:14:01 am
Well of course I am talking 1.5 and actually the core router seems to work pretty well for me with civicrm in 1.5, but in Joomla the sef urls are created by the router. Mostly the way to do sef urls for third party components (just as for the core components) is to build a router that takes apart the dynamic url and makes it into a "nice" url using (usually) the menu alias.


...
function ContentBuildRoute(&$query)
{
   $segments = array();

   if(isset($query['view']))
   {
      if(empty($query['Itemid'])) {
         $segments[] = $query['view'];
      }

      unset($query['view']);
   };
...
   if(isset($query['id'])) {
      if (empty($query['Itemid'])) {
         $segments[] = $query['id'];
      } else {
         $menu = &JSite::getMenu();
         $menuItem = &$menu->getItem( $query['Itemid'] );
         if (isset($menuItem->query['id'])) {
            if($query['id'] != $menuItem->query['id']) {
               $segments[] = $query['id'];
            }
         } else {
            $segments[] = $query['id'];
         }
      }
      unset($query['id']);
   };
...


...

function ContentParseRoute($segments)
{
   $vars = array();

   //Get the active menu item
   $menu =& JSite::getMenu();
   $item =& $menu->getActive();

   // Count route segments
   $count = count($segments);

   //Standard routing for articles
   if(!isset($item))
   {
      $vars['view']  = $segments[0];
      $vars['id']    = $segments[$count - 1];
      return $vars;
   }

   //Handle View and Identifier


switch($item->query['view'])
   {
...
      case 'article' :
      {
         $vars['id']     = $segments[$count-1];
         $vars['view'] = 'article';
      } break;



...

(probably i didn't copy all of the right parts but you get the idea, this is from /components/com_content/router.php)

changes this

http://localhost/currentsvn/index.php?option=com_content&view=article&id=26&Itemid=40

to
http://localhost/currentsvn/index.php/extensions


But it's really a part of building the front end to the civicrm component.  :)


Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Installing CiviCRM »
  • Joomla! Installations (Moderator: Deepak Srivastava) »
  • Duplicate menu ids

This forum was archived on 2017-11-26.