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 »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Trackable URLs and opens not functioning correctly in CiviMail messages
Pages: [1]

Author Topic: Trackable URLs and opens not functioning correctly in CiviMail messages  (Read 1456 times)

mirrorstage

  • I post occasionally
  • **
  • Posts: 57
  • Karma: 1
  • CiviCRM version: 4.6.7
  • CMS version: Drupal 6.37
  • MySQL version: 5.6.23
  • PHP version: 5.4.42
Trackable URLs and opens not functioning correctly in CiviMail messages
March 13, 2011, 08:37:42 pm
If I select the option to track click-throughs when I compose a CiviMail message, the message URLs send readers clicking on any internal message links to:
mysite.org/sites/default/modules/civicrm/extern/url/php?u=42&qid=1102

which opens page with the following message:
 
"Could not find valid configuration dir. best guess:/home/mysite/public_html/sites/default/modules/civicrm/.../.../sites

If this is a standalone installation (i.e. not a Drupal or Joomla module) and you'd like to re-initialize, click here."

If I de-select the option to track click-throughs, the links work fine. Is there something I am supposed to have configured? I've combed through the documentation and forums, and cannot figure out what I missed or what I have done wrong.

Opens don't seem to be tracking correctly, either, which I don't know whether it's related or not. Can anyone help point me in the right direction, so I can track click-through and opens?

Thanks for any help you can provide!

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: Trackable URLs and opens not functioning correctly in CiviMail messages
March 14, 2011, 09:31:51 am

can u follow the steps here and create a settings_location.php file

http://wiki.civicrm.org/confluence/display/CRMDOC33/Upgrade+Drupal+Sites+to+3.3 (Search for settings_location)

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

mirrorstage

  • I post occasionally
  • **
  • Posts: 57
  • Karma: 1
  • CiviCRM version: 4.6.7
  • CMS version: Drupal 6.37
  • MySQL version: 5.6.23
  • PHP version: 5.4.42
Re: Trackable URLs and opens not functioning correctly in CiviMail messages
March 16, 2011, 02:01:53 pm
I followed the steps at the link you provided to make sure I had upgraded correctly to 3.3.5, but I can't find any information anywhere about how to create a settings_location.php file, so I have no idea what you're referring to.

Where would/should it be located--meaning in which file in my directory? The same place the civicrm.settings.php file? Or in one of the other subdirectories?

mirrorstage

  • I post occasionally
  • **
  • Posts: 57
  • Karma: 1
  • CiviCRM version: 4.6.7
  • CMS version: Drupal 6.37
  • MySQL version: 5.6.23
  • PHP version: 5.4.42
Re: Trackable URLs and opens not functioning correctly in CiviMail messages
March 22, 2011, 04:48:58 pm
Since I didn't get a response here, I tried starting a new topic called settings_location.php, but thought I should also share this info here...

From http://wiki.civicrm.org/confluence/display/CRMDOC33/Upgrade+Drupal+Sites+to+3.3#UpgradeDrupalSitesto3.3-Calendarwidgetdoesn%27twork%28throwsaJavascripterror%29%2Cand%2ForCiviMailscriptsforopentracking%2CSOAPauthentication%2Cetc.don%27tfunction.

Calendar widget doesn't work (throws a Javascript error), and/or CiviMail scripts for open tracking, SOAP authentication, etc. don't function.

    If your CiviCRM codebase is NOT located in either <drupal root>/modules/civicrm or <drupal root>/sites/all/modules (i.e. you are using a symlink from there to your codebase) - you will need to create a local file in the top-level directory of your codebase which points to the location of your drupal sites directory.

    // Create a new file - settings_location.php
    // Enter the following code (substitute the actual location of your
    // <drupal root>/sites directory)
    <?php
    define( 'CIVICRM_CONFDIR', '/home/lobo/public_html/drupal/sites' );
    ?>

Okay, so since my civicrm folder is in sites/default/modules, instead of sites/all/modules, where should the settings_location.php file be located--meaning in which folder in my directory? The same place the civicrm.settings.php file? Or in one of the other subdirectories?

And all it needs to contain is: <?php
define( 'CIVICRM_CONFDIR', '/home/lobo/public_html/drupal/sites' );
?> with my info subbed in? Should it be home/mirrorst/public_html/sites or should it be home/mirrorst/public_html/sites/default/modules?

I'd really like to be able to accurately track opens, bounces click-throughs and forwards. Someone please help me figure out how to properly configure the system to be able to do so! Thanks so much!

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Trackable URLs and opens not functioning correctly in CiviMail messages
March 23, 2011, 01:35:39 am
1) What's the complete path for your civicrm directory  ?
That's where your settings_location file has to be

2) What's the compete path to your drupal/sites directory ?

that's the value you need to put in the file


X+
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

mirrorstage

  • I post occasionally
  • **
  • Posts: 57
  • Karma: 1
  • CiviCRM version: 4.6.7
  • CMS version: Drupal 6.37
  • MySQL version: 5.6.23
  • PHP version: 5.4.42
Re: Trackable URLs and opens not functioning correctly in CiviMail messages
March 23, 2011, 12:24:14 pm
My civicrm directory is in pubic_html/sites/default/modules/ and my drupal directory is public_html/sites/

So, if I understand you correctly, I need to put my settings_location.php file in the public_html/sites/default/modules/civicrm/ folder with the following value:

<?php
define( 'CIVICRM_CONFDIR', '/home/mirrost/public_html/drupal/sites' );
?>

Will do and will report back. Thanks!

mirrorstage

  • I post occasionally
  • **
  • Posts: 57
  • Karma: 1
  • CiviCRM version: 4.6.7
  • CMS version: Drupal 6.37
  • MySQL version: 5.6.23
  • PHP version: 5.4.42
Re: Trackable URLs and opens not functioning correctly in CiviMail messages
March 23, 2011, 12:47:30 pm
I moved the settings_location.php file configured as described above, and sent a test message. Now the links click through to an Error page with the following message:

Not Found

The requested URL /sites/default/modules/civicrm/extern/www.mirrorstage.org/ was not found on this server.

So, it seems we're making progress, but have not yet fully solved the problem. What next?

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Trackable URLs and opens not functioning correctly in CiviMail messages
March 24, 2011, 09:05:49 am
Could you describe:

1)what config you have on the resource url (all)
2) what civicrm_root
3) what's exactly the link as in the email (copy paste the href)
4)What's the url of your site
5) and be sure the data your contact profile are up to date (the versions)

Something is not configured properly, somewhere.
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

mirrorstage

  • I post occasionally
  • **
  • Posts: 57
  • Karma: 1
  • CiviCRM version: 4.6.7
  • CMS version: Drupal 6.37
  • MySQL version: 5.6.23
  • PHP version: 5.4.42
Re: Trackable URLs and opens not functioning correctly in CiviMail messages
March 24, 2011, 05:32:13 pm
I would, if I could, but I'm not clear on what you are asking in 1 & 2.

1. Where would I find the config for resource url (all)? Is it in a particular settings file? In CiviMail Admin? I don't know where to look to answer your question.

2. Describe what civicrm_root? Again, I don't understand what you are asking. I'm pretty much a novice when it comes to Drupal and CiviCRM, so I need clearer directions to follow. I'm still learning my way around.

3. <a href="http://www.mirrorstage.org/?q=toastnjam2011">Toast-n-Jam 2011</a>

Aha! Realized the href code for the link I had been testing was configured incorrectly--of course I managed to select the only incorrectly coded link in the test email! When I corrected it and sent a test message, the link worked correctly and opened a new window in my browser with the URL http://www.mirrorstage.org/?q=toastnjam2011&

4. The URL of my site is http://www.mirrorstage.org

5. The data in my contact profile is up to date. We are using CiviCRM 3.3.5 on Drupal 6.2 with PHP 5.3.4 and MySQL 5.0.91.

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Old sections (read-only, deprecated) »
  • Support »
  • Using CiviCRM »
  • Using CiviMail (Moderator: Piotr Szotkowski) »
  • Trackable URLs and opens not functioning correctly in CiviMail messages

This forum was archived on 2017-11-26.