Changeset 4085

Show
Ignore:
Timestamp:
Fri Nov 11 16:45:42 2005
Author:
paul
Message:

First patch for rewrite of the article list screen - you can now perform actions on multiple articles at once. Fixed a number of issues with the API - including making the Article class constructor easier to use. Changed ArticlePublish? and IssuePublish? classes to use new database table. Added javascript calendar. Added links to Pub/Issue/Section edit screens so that all actions are available. Started adding log messages into the API instead of from the admin interface.

Files:

Legend:

Unmodified
Added
Removed
Modified
  • trunk/campsite/implementation/management/priv/lang/ro/articles.php

    r3953 r4085  
    8 8 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Articolul $1 a fost adăugat la $2. $3 din $4. $5 din $6");  
    9 9 regGS("Are you sure you want to delete the article $1 ($2)?", "Doriţi să ştergeţi articolul $1 ($2)?");  
    10   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Articolul $1 ($2) a fost şters din $3. $4 din $5. $6 ($7) din $8");  
    11 10 regGS("Change article status", "Modific starea articolului");  
    12 11 regGS("Change the status of article $1 ($2) from $3 to", "Modific starea articolului $1 ($2) de la $3 la");  
    13   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Starea articolului $1 din $2. $3 din $4. $5 ($6) al $7 a fost modificată");  
    14 12 regGS("Translate article", "Traducere articol");  
    15   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Nu aveţi dreptul să modificaţi articolul. Puteţi să editaţi numai articolele dumneavoastră. Odată propus un articol poate fi modificat numai de utilizatori autorizaţi.");  
    16   regGS("Edit article details", "Editează articolul");  
      13 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Nu aveţi dreptul să modificaţi articolul. Puteţi să editaţi numai articolele dumneavoastră. Odată propus un articol poate fi modificat numai de utilizatori autorizaţi.");  
      14 regGS("Edit article", "Editează articolul");  
    17 15 regGS("Allow users without subscriptions to view the article", "Autorizează accesul cititorilor fără subscriere la articol");  
    18 16 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "");  
  • trunk/campsite/implementation/management/priv/lang/ro/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "");  
    3 3 regGS("Back to Article Image List", "");  
    4   regGS("Add new image", "Adaugă imagine");  
    5   regGS("Add an existing image", "Adaugă o imagine existentă");  
      4 regGS("Add New Image", "Adaugă imagine");  
      5 regGS("Add an Existing Image", "Adaugă o imagine existentă");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Data (aaaa-ll-zz)");  
    7 7 regGS("Delete image $1", "Şterge imaginea $1");  
  • trunk/campsite/implementation/management/priv/lang/ro/issues.php

    r3953 r4085  
    29 29 regGS("Are you sure you want to delete the issue $1?", "Doriţi să ştergeţi ediţia $1?");  
    30 30 regGS("Deleting issue", "Şterg ediţia");  
    31   regGS("The issue $1 has ben deleted.", "Ediţia $1 a fost ştearsă");  
      31 regGS("The issue $1 has been deleted.", "Ediţia $1 a fost ştearsă");  
    31 31 regGS("The issue $1 could not be deleted.", "Ediţia $1 nu poate fi ştearsă");  
    32 32 regGS("All sections from Issue $1 from publication $2 deleted", "Toate secţiunile din ediţia $1 din publicaţia $2 au fost şterse");  
  • trunk/campsite/implementation/management/priv/lang/ro/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Adaugă imagine");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Data (aaaa-ll-zz)");  
    9 10 regGS("Used in articles", "");  
    10 11 regGS("View image", "Vizualizare imagine");  
    11   regGS("Back to image archive", "");  
    12 12 regGS("Change image information", "Modifică datele imaginii");  
    13 13 regGS("Changed image properties of $1", "Datele imaginii $1 au fost modificate");  
  • trunk/campsite/implementation/management/priv/lang/ro/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Nume");  
    3 4 regGS("Delete publication $1", "Şterge publicaţia $1");  
  • trunk/campsite/implementation/management/priv/lang/zh/articles.php

    r3953 r4085  
    8 8 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "文章$1被加到$2,$3来自$4。$6中的$5");  
    9 9 regGS("Are you sure you want to delete the article $1 ($2)?", "您要删除文章$1($2)");  
    10   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "文章 $1 ($2)从$3中删除. $4从$5中. $6 ($7)从$8中");  
    11 10 regGS("Change article status", "修改文章状态");  
    12 11 regGS("Change the status of article $1 ($2) from $3 to", "改变文章$1 ($2) 的状态从$3到");  
    13   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "文章$1 的状态从$2. $3 从$4. $5 ($6)从 $7已改变");  
    14 12 regGS("Translate article", "翻译文章");  
    15   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "您无权修改此文章,你只能编辑自己的文章,提交的文章只能由审定的用户修改");  
    16   regGS("Edit article details", "编辑文章详情");  
      13 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "您无权修改此文章,你只能编辑自己的文章,提交的文章只能由审定的用户修改");  
      14 regGS("Edit article", "编辑文章详情");  
    17 15 regGS("Allow users without subscriptions to view the article", "允许无订阅的用户阅读文章");  
    18 16 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "");  
  • trunk/campsite/implementation/management/priv/lang/zh/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "");  
    3 3 regGS("Back to Article Image List", "");  
    4   regGS("Add new image", "添加新图片");  
    5   regGS("Add an existing image", "");  
      4 regGS("Add New Image", "添加新图片");  
      5 regGS("Add an Existing Image", "");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "日期(yyyy-mm-dd)");  
    7 7 regGS("Delete image $1", "删除图片$1");  
  • trunk/campsite/implementation/management/priv/lang/zh/issues.php

    r3953 r4085  
    29 29 regGS("Are you sure you want to delete the issue $1?", "你确认删除议题$1");  
    30 30 regGS("Deleting issue", "正在删除议题");  
    31   regGS("The issue $1 has ben deleted.", "议题$1已被删除");  
      31 regGS("The issue $1 has been deleted.", "议题$1已被删除");  
    31 31 regGS("The issue $1 could not be deleted.", "议题$1不能被删除");  
    32 32 regGS("All sections from Issue $1 from publication $2 deleted", "来自发布$2的议题$1的所有区已删除");  
  • trunk/campsite/implementation/management/priv/lang/zh/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "添加新图片");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "日期(yyyy-mm-dd)");  
    9 10 regGS("Used in articles", "");  
    10 11 regGS("View image", "查看图片");  
    11   regGS("Back to image archive", "");  
    12 12 regGS("Change image information", "修改图片信息");  
    13 13 regGS("Changed image properties of $1", "已变化$1的图片属性");  
  • trunk/campsite/implementation/management/priv/lang/zh/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "名称");  
    3 4 regGS("Delete publication $1", "删除出版物$1");  
  • trunk/campsite/implementation/management/priv/lang/ar/articles.php

    r3953 r4085  
    7 7 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "تمّت إضافة المقال $1 إلى $2. $3 من $4 و$5 من $6");  
    8 8 regGS("Are you sure you want to delete the article $1 ($2)?", "هل أنت متأكد من أنك تريد إلغاء المقال $1 ($2)؟");  
    9   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "تمّ إلغاء المقال $1 ($2) من$3. $4 من $5.$6 ($7) من$8");  
    10 9 regGS("Change article status", "غيّر وضع المقال");  
    11 10 regGS("Change the status of article $1 ($2) from $3 to", "تغيير وضع المقال $1 ($2) من $3");  
    12   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "تمّ تغيير وضع المقال $1 من $2. $3 من $4. $5  ($6) من $7");  
    13 11 regGS("Translate article", "ترجم المقال");  
    14   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "لا تملك صلاحية تعديل هذا المقال. يحق لك تعديل مقالاتك وعند اعتماد المقال يمكن تغيره من قبل الاشخاص المخوليين فقط");  
    15   regGS("Edit article details", "تحرير المقال");  
      12 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "لا تملك صلاحية تعديل هذا المقال. يحق لك تعديل مقالاتك وعند اعتماد المقال يمكن تغيره من قبل الاشخاص المخوليين فقط");  
      13 regGS("Edit article", "تحرير المقال");  
    16 14 regGS("Allow users without subscriptions to view the article", "اسمع للمستخدمين من دون اشتراكات رؤية هذا المقال");  
    17 15 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "تم اغلاق المقال بواسطة 1$ (2$) منذ 3$ ساعات و4$ دقائق");  
    27 25 regGS("Edit article types", "");  
    28 26 regGS("Could not save the article. It has been locked by $1 $2 hours and $3 minutes ago.", "");  
    29   regGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users.", "");  
      27 regGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.", "");  
    29 27 regGS("You do not have the right to delete articles.", "");  
    30 28 regGS("You must select an article type.", "");  
  • trunk/campsite/implementation/management/priv/lang/ar/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "قائمة صور المقال");  
    3 3 regGS("Back to Article Image List", "العودة الى قائمة صور المقال");  
    4   regGS("Add new image", "أضف صورة جديدة");  
    5   regGS("Add an existing image", "اضافة صورة موجودة");  
      4 regGS("Add New Image", "أضف صورة جديدة");  
      5 regGS("Add an Existing Image", "اضافة صورة موجودة");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "التاريخ <br> (السنة، الشهرة، اليوم)");  
    7 7 regGS("Delete image $1", "الغاء الصورة $1");  
  • trunk/campsite/implementation/management/priv/lang/ar/issues.php

    r3953 r4085  
    30 30 regGS("Are you sure you want to delete the issue $1?", "هل أنت متأكد من أنك تريد إلغاء الإصدار $1 ؟  ");  
    31 31 regGS("Deleting issue", "إلغاء الإصدار");  
    32   regGS("The issue $1 has ben deleted.", "تمّ  إلغاء الإصدار $1");  
      32 regGS("The issue $1 has been deleted.", "تمّ  إلغاء الإصدار $1");  
    32 32 regGS("The issue $1 could not be deleted.", "لا يمكن إلغاء الإصدار $1");  
    33 33 regGS("All sections from Issue $1 from publication $2 deleted", "تمّ إلغاء كل أبواب الإصدار $1 في المنشور $2");  
  • trunk/campsite/implementation/management/priv/lang/ar/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "أضف صورة جديدة");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "التاريخ <br> (السنة، الشهرة، اليوم)");  
    9 10 regGS("Used in articles", "مستخدمة في المقالات");  
    10 11 regGS("View image", "مشاهدة الصورة");  
    11   regGS("Back to image archive", "العودة إلى أرشيف الصور");  
    12 12 regGS("Change image information", "غيّر معلومات الصورة");  
    13 13 regGS("Changed image properties of $1", "تمّ تغيير خصائص الصورة $1");  
  • trunk/campsite/implementation/management/priv/lang/ar/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", " الاسم (اضغط لترى الإصدارات)");  
    3 4 regGS("Delete publication $1", "الغاء المنشور $1");  
  • trunk/campsite/implementation/management/priv/lang/en/users.php

    r3953 r4085  
    5 5 regGS("Add new IP address group", "Add new IP address group");  
    6 6 regGS("Staff management", "Staff management");  
    7   regGS("Subscribers management", "Subscribers management");  
      7 regGS("Subscriber management", "Subscriber management");  
    7 7 regGS("Edit user rights", "Edit user rights");  
    8 8 regGS("User Name", "User Name");  
  • trunk/campsite/implementation/management/priv/lang/en/languages.php

    r3953 r4085  
    36 36 regGS("Sunday", "Sunday");  
    37 37 regGS("You do not have the right to add new languages.", "You do not have the right to add new languages.");  
    38   regGS("There are $1 classes(s) left.", "There are $1 classes(s) left.");  
    39 38 regGS("There are $1 issue(s) left.", "There are $1 issue(s) left.");  
    40   regGS("There are $1 keyword(s) left.", "There are $1 keyword(s) left.");  
    41 39 ?>  
  • trunk/campsite/implementation/management/priv/lang/en/articles.php

    r3953 r4085  
    7 7 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Article $1 added to $2. $3 from $4. $5 of $6");  
    8 8 regGS("Are you sure you want to delete the article $1 ($2)?", "Are you sure you want to delete the article $1 ($2)?");  
    9   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8");  
    10 9 regGS("Change article status", "Change article status");  
    11 10 regGS("Change the status of article $1 ($2) from $3 to", "Change the status of article $1 ($2) from $3 to");  
    12   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed");  
    13 11 regGS("Translate article", "Translate article");  
    14   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.");  
    15   regGS("Edit article details", "Edit article details");  
      12 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.");  
      13 regGS("Edit article", "Edit article");  
    16 14 regGS("Allow users without subscriptions to view the article", "Allow users without subscriptions to view the article");  
    17 15 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.");  
    27 25 regGS("Edit article types", "Edit article types");  
    28 26 regGS("Could not save the article. It has been locked by $1 $2 hours and $3 minutes ago.", "Could not save the article. It has been locked by $1 $2 hours and $3 minutes ago.");  
    29   regGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users.", "You do not have the right to change this article status. Once submitted an article can only changed by authorized users.");  
      27 regGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.", "You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.");  
    29 27 regGS("You do not have the right to delete articles.", "You do not have the right to delete articles.");  
    30 28 regGS("You must select an article type.", "You must select an article type.");  
  • trunk/campsite/implementation/management/priv/lang/en/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.");  
    2 2 regGS("Article Image List", "Article Image List");  
    3 3 regGS("Back to Article Image List", "Back to Article Image List");  
    4   regGS("Add new image", "Add New Image");  
    5   regGS("Add an existing image", "Add an Existing Image");  
      4 regGS("Add New Image", "Add New Image");  
      5 regGS("Add an Existing Image", "Add an Existing Image");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Date<BR><SMALL>(yyyy-mm-dd)</SMALL>");  
    7   regGS("Remove Image From Article", "<nobr>Remove Image</nobr> <nobr>From Article</nobr>");  
    8   regGS("Link Image to Article", "<nobr>Link Image to Article</nobr>");  
      7 regGS("Remove Image From Article", "Remove Image From Article");  
      8 regGS("Link Image to Article", "Link Image to Article");  
    9 9 regGS("Please enter a number for the image.", "Please enter a number for the image.");  
    10 10 regGS("Please enter a description for the image.", "Please enter a description for the image.");  
    22 22 regGS("Image $1 linked to article $2", "Image $1 linked to article $2");  
    23 23 regGS("Image $1 unlinked from $2", "Image $1 unlinked from $2");  
      24 regGS("Are you sure you want to remove the image \\'$1\\' from the article?", "Are you sure you want to remove the image \\'$1\\' from the article?");  
    24 25 ?>  
  • trunk/campsite/implementation/management/priv/lang/en/issues.php

    r3953 r4085  
    22 22 regGS("Are you sure you want to delete the issue $1?", "Are you sure you want to delete the issue $1?");  
    23 23 regGS("Deleting issue", "Deleting issue");  
    24   regGS("The issue $1 has ben deleted.", "The issue $1 has ben deleted.");  
      24 regGS("The issue $1 has been deleted.", "The issue $1 has been deleted.");  
    24 24 regGS("The issue $1 could not be deleted.", "The issue $1 could not be deleted.");  
    25 25 regGS("All sections from Issue $1 from publication $2 deleted", "All sections from Issue $1 from publication $2 deleted");  
  • trunk/campsite/implementation/management/priv/lang/en/localizer.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("Log Messages", "Log Messages");  
    2 3 regGS("edit '$1'", "edit '$1'");  
    3 4 regGS("edit \"$1\"", "edit \"$1\"");  
  • trunk/campsite/implementation/management/priv/lang/en/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "You must select an image file to upload.");  
    2 3 regGS("Add new image", "Add new image");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Date <SMALL>(yyyy-mm-dd)</SMALL>");  
    9 10 regGS("Used in articles", "Used in articles");  
    10 11 regGS("View image", "View image");  
    11   regGS("Back to image archive", "Back to image archive");  
    12 12 regGS("Change image information", "Change image information");  
    13 13 regGS("Changed image properties of $1", "Changed image properties of $1");  
  • trunk/campsite/implementation/management/priv/lang/en/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "Go To Issues");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Name<BR><SMALL>(click to see issues)</SMALL>");  
    3 4 regGS("Delete publication $1", "Delete publication $1");  
  • trunk/campsite/implementation/management/priv/lang/pt/articles.php

    r3953 r4085  
    8 8 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Artigo $1 adicionado a $2. $3 de $4. $5 de $6");  
    9 9 regGS("Are you sure you want to delete the article $1 ($2)?", "Confirme a Eliminação do Artigo $1 ($2)?");  
    10   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Artigo $1 ($2) foi eliminado de $3. $4 de $5. $6 ($7) de $8");  
    11 10 regGS("Change article status", "Alterar Estado do Artigo");  
    12 11 regGS("Change the status of article $1 ($2) from $3 to", "Alterar Estado do Artigo $1 ($2) de $3 para");  
    13   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Alteração no Artigo $1 de $2, $3 de $4. $5 ($6) de $7");  
    14 12 regGS("Translate article", "Traduzir Artigo");  
    15   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Não tem permissões para alterar o Estado do Artigo. Apenas pode alterar os seus artigos, mas após um artigo ser submetido apenas poderá ser alterado por Utilizadores autorizados pelo Sistema.");  
    16   regGS("Edit article details", "Editar Detalhes do Artigo");  
      13 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Não tem permissões para alterar o Estado do Artigo. Apenas pode alterar os seus artigos, mas após um artigo ser submetido apenas poderá ser alterado por Utilizadores autorizados pelo Sistema.");  
      14 regGS("Edit article", "Editar Detalhes do Artigo");  
    17 15 regGS("Allow users without subscriptions to view the article", "Permitir que leitores sem assinatura vejam Artigo.");  
    18 16 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "");  
  • trunk/campsite/implementation/management/priv/lang/pt/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "");  
    3 3 regGS("Back to Article Image List", "");  
    4   regGS("Add new image", "Adicionar Imagem");  
    5   regGS("Add an existing image", "");  
      4 regGS("Add New Image", "Adicionar Imagem");  
      5 regGS("Add an Existing Image", "");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Data (aaaa-mm-dd)");  
    7 7 regGS("Delete image $1", "Apagar imagem");  
  • trunk/campsite/implementation/management/priv/lang/pt/issues.php

    r3953 r4085  
    28 28 regGS("Are you sure you want to delete the issue $1?", "Tem a certeza que deseja eliminar a Edição $1?");  
    29 29 regGS("Deleting issue", "Eliminando Edição");  
    30   regGS("The issue $1 has ben deleted.", "A Edição $1 foi eliminada.");  
      30 regGS("The issue $1 has been deleted.", "A Edição $1 foi eliminada.");  
    30 30 regGS("The issue $1 could not be deleted.", "A Edição $1 não pode ser eliminada.");  
    31 31 regGS("All sections from Issue $1 from publication $2 deleted", "Todas as Secções da Edição $1 da Publicação $2 foram eliminadas");  
  • trunk/campsite/implementation/management/priv/lang/pt/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Adicionar Imagem");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Data (aaaa-mm-dd)");  
    9 10 regGS("Used in articles", "");  
    10 11 regGS("View image", "Ver imagem");  
    11   regGS("Back to image archive", "");  
    12 12 regGS("Change image information", "Alterar informações da imagem");  
    13 13 regGS("Changed image properties of $1", "Alterando as informações da imagem $1");  
  • trunk/campsite/implementation/management/priv/lang/pt/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Nome (Carregue para ver Edições)");  
    3 4 regGS("Delete publication $1", "Apagar Publicação");  
  • trunk/campsite/implementation/management/priv/lang/sr/users.php

    r3953 r4085  
    5 5 regGS("Add new IP address group", "Додајте нову корисничку групу засновану на IP адреси");  
    6 6 regGS("Staff management", "Управљање сарадничким налозима");  
    7   regGS("Subscribers management", "Управљање претплатничким налозима");  
      7 regGS("Subscriber management", "Управљање претплатничким налозима");  
    7 7 regGS("Edit user rights", "Прикажи корисничка права");  
    8 8 regGS("User Name", "Корисничко име");  
  • trunk/campsite/implementation/management/priv/lang/sr/languages.php

    r3953 r4085  
    36 36 regGS("Sunday", "недеља");  
    37 37 regGS("You do not have the right to add new languages.", "Немате право да додајете нове језике.");  
    38   regGS("There are $1 classes(s) left.", "Преостало је  $1 класа.");  
    39 38 regGS("There are $1 issue(s) left.", "Преостало је  $1издања.");  
    40   regGS("There are $1 keyword(s) left.", "Преостало је  $1 кључних речи.");  
    41 39 regGS("The language $1 has been successfuly added.", "Језик $1 успешно је додат");  
    42 40 regGS("Please check if a language with the same name does not already exist.", "Проверите да ли језик са истим именом већ не постоји");  
  • trunk/campsite/implementation/management/priv/lang/sr/articles.php

    r3953 r4085  
    7 7 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Чланак $1 додат у $2. $3 из $4. $5 од $6");  
    8 8 regGS("Are you sure you want to delete the article $1 ($2)?", "Да ли сте сигурни да желите да обришете чланак $1 ($2)?");  
    9   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Чланак $1 ($2) је обрисан из $3. $4 из $5. 46 ($7) од $8");  
    10 9 regGS("Change article status", "Промени статус чланка");  
    11 10 regGS("Change the status of article $1 ($2) from $3 to", "Промени статус чланка $1 ($2) из $3 у");  
    12   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Статус чланка $1 из $2. $3 из $4. $5 ($6) од $7 промењен");  
    13 11 regGS("Translate article", "Преведи чланак");  
    14   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Немате право да мењате чланак. Можете прегледати једино сопствене чланке, а једном пријављени чланак може бити мењан само од стране овлашћених корисника");  
    15   regGS("Edit article details", "Прикажи детаље чланка");  
      12 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Немате право да мењате чланак. Можете прегледати једино сопствене чланке, а једном пријављени чланак може бити мењан само од стране овлашћених корисника");  
      13 regGS("Edit article", "Прикажи детаље чланка");  
    16 14 regGS("Allow users without subscriptions to view the article", "Дозволи корисницима без претплате да виде чланак");  
    17 15 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "Чланак је закључан од стране $1 ($2) пре $3 час(ов)а и $4 минута. ");  
    27 25 regGS("Edit article types", "Прикажи типове чланака");  
    28 26 regGS("Could not save the article. It has been locked by $1 $2 hours and $3 minutes ago.", "Чланак не може бити снимљен. Закључан је од стране $1 пре $2 часова и $3 минута.");  
    29   regGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users.", "Немате право да мењате статус чланка. Предатом чланку статус може променити само овлашћени корисник.");  
      27 regGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.", "Немате право да мењате статус чланка. Предатом чланку статус може променити само овлашћени корисник.");  
    29 27 regGS("You do not have the right to delete articles.", "Немате право да бришете чланке.");  
    30 28 regGS("You must select an article type.", "Морате изабрати тип чланка.");  
  • trunk/campsite/implementation/management/priv/lang/sr/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Немате право да мењате чланак. Можете мењати само своје чланке, а предатим чланцима статус може променити само овлашћени корисник.");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Немате право да мењате чланак. Можете мењати само своје чланке, а предатим чланцима статус може променити само овлашћени корисник.");  
    2 2 regGS("Article Image List", "Листа слика у чланку");  
    3 3 regGS("Back to Article Image List", "Назад на листу слика у чланку");  
    4   regGS("Add new image", "Додајте нову слику");  
    5   regGS("Add an existing image", "Додај постојећу слику");  
      4 regGS("Add New Image", "Додајте нову слику");  
      5 regGS("Add an Existing Image", "Додај постојећу слику");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Датум<br><small>(гггг-мм-дд)</small>");  
    7 7 regGS("Remove Image From Article", "Уклони слику из чланка");  
     
    13 13 regGS("There are currently no images associated with this article.", "Тренутно нема слика повезаних са овим чланком.");  
    14 14 regGS("Click one of the \"Add Image\" links above to add one.", "Кликните на један од 'Додај слику' линкова да би сте је додали.");  
    15   regGS("Are you sure you want to remove the image \'$1\' from the article?", "");  
      15 regGS("Are you sure you want to remove the image \'$1\' from the article?", "Да ли сте сигурни да желите да уконите слику \'$1\' из чланка?");  
    15 15 regGS("Change image information", "Промени податке о слици");  
    16 16 regGS("Changed image properties of $1", "Промењене особине слике $1");  
    27 27 regGS("Are you sure you want to delete the image '$1'?", "Да ли сте сигурни да желите да обришете слику '$1'?");  
    28 28 regGS("Unlink image $1", "Раскини везу слике $1");  
    29   regGS("Are you sure you want to remove the image \\'$1\\' from the article?", "Да ли сте сигурни да желите да уконите слику \'$1\' из чланка?");  
    30 29 ?>  
  • trunk/campsite/implementation/management/priv/lang/sr/issues.php

    r3953 r4085  
    22 22 regGS("Are you sure you want to delete the issue $1?", "Сигурни сте да желите да обришете издање $1?");  
    23 23 regGS("Deleting issue", "Брисање издања");  
    24   regGS("The issue $1 has ben deleted.", "Издање $1 је избрисано");  
      24 regGS("The issue $1 has been deleted.", "Издање $1 је избрисано");  
    24 24 regGS("The issue $1 could not be deleted.", "Издање $1 не може бити избрисано");  
    25 25 regGS("All sections from Issue $1 from publication $2 deleted", "Све рубрике издања $1 из публикације $2 су обрисане");  
  • trunk/campsite/implementation/management/priv/lang/sr/localizer.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("Log Messages", "");  
    2 3 regGS("edit '$1'", "прикажи '$1'");  
    3 4 regGS("edit \"$1\"", "прикажи \"$1\"");  
  • trunk/campsite/implementation/management/priv/lang/sr/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Додајте нову слику");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Датум (гггг-мм-дд)");  
    9 10 regGS("Used in articles", "Користи се у чланцима");  
    10 11 regGS("View image", "Прикажи слику");  
    11   regGS("Back to image archive", "Назад на фото архиву");  
    12 12 regGS("Change image information", "Промени податке о слици");  
    13 13 regGS("Changed image properties of $1", "Промењене особине слике $1");  
  • trunk/campsite/implementation/management/priv/lang/sr/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Име<br><small>(кликните за преглед издања)</small>");  
    3 4 regGS("Delete publication $1", "Обриши публикацију $1");  
  • trunk/campsite/implementation/management/priv/lang/ru/users.php

    r3953 r4085  
    5 5 regGS("Add new IP address group", "Добавление новой группы IP-адресов");  
    6 6 regGS("Staff management", "Управление персоналом");  
    7   regGS("Subscribers management", "Управление подписчиками");  
      7 regGS("Subscriber management", "Управление подписчиками");  
    7 7 regGS("Edit user rights", "Редактировать права пользователей");  
    8 8 regGS("User Name", "Имя пользователя");  
  • trunk/campsite/implementation/management/priv/lang/ru/languages.php

    r3953 r4085  
    36 36 regGS("Sunday", "Воскресенье");  
    37 37 regGS("You do not have the right to add new languages.", "В не имеете права добавлять новые языки.");  
    38   regGS("There are $1 classes(s) left.", "Осталось классов: $1");  
    39 38 regGS("There are $1 issue(s) left.", "Осталось выпусков: $1");  
    40   regGS("There are $1 keyword(s) left.", "Осталось ключевых слов: $1");  
    41 39 regGS("No such language.", "Нет такого языка.");  
    42 40 regGS("The language $1 has been successfuly added.", "Язык $1 был успешно добавлен.");  
  • trunk/campsite/implementation/management/priv/lang/ru/articles.php

    r3953 r4085  
    7 7 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Статья $1 добавлена к $2. $3 из $4. $5 из $6");  
    8 8 regGS("Are you sure you want to delete the article $1 ($2)?", "Вы уверены, что хотите удалить статью $1 ($2)?");  
    9   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Статья $1 ($2) удалена из $3. $4 из $5. $6 ($7) из $8");  
    10 9 regGS("Change article status", "Изменить статус статьи");  
    11 10 regGS("Change the status of article $1 ($2) from $3 to", "Изменить статус статьи $1 ($2) из $3 в");  
    12   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Изменен статус статьи $1 из $2. $3 из $4. $5 ($6) из $7");  
    13 11 regGS("Translate article", "Перевести статью");  
    14   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Вы не имеете права изменения этой статьи. Вы можете только редактировать свои собственные статьи и, будучи отправленной, статья может быть изменена только уполномоченными пользователями.");  
    15   regGS("Edit article details", "Редактировать параметры статьи");  
      12 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Вы не имеете права изменения этой статьи. Вы можете только редактировать свои собственные статьи и, будучи отправленной, статья может быть изменена только уполномоченными пользователями.");  
      13 regGS("Edit article", "Редактировать параметры статьи");  
    16 14 regGS("Allow users without subscriptions to view the article", "Позволить пользователям без подписки просматривать статью");  
    17 15 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "Статья была заблокирована пользователем $1 ($2) $3 часа и $4 минут назад.");  
    27 25 regGS("Edit article types", "Редактировать типы статей");  
    28 26 regGS("Could not save the article. It has been locked by $1 $2 hours and $3 minutes ago.", "Не удалось сохранить статью. Она заблокирована пользователем $1 $2 часа и $3 минут назад.");  
    29   regGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users.", "Вы не имеете права изменять состояние этой статьи. Будучи отправленной статья может быть изменена только уполномоченным пользователем.");  
      27 regGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.", "Вы не имеете права изменять состояние этой статьи. Будучи отправленной статья может быть изменена только уполномоченным пользователем.");  
    29 27 regGS("You do not have the right to delete articles.", "Вы не имеете права удалять статьи.");  
    30 28 regGS("You must select an article type.", "Вы должны выбрать тип статьи.");  
  • trunk/campsite/implementation/management/priv/lang/ru/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Вы не имеете права изменять эту статью. Вы можете только редактировать собственные статьи, и будучи отправленной, статья может быть изменена только уполномоченным пользователем.");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Вы не имеете права изменять эту статью. Вы можете только редактировать собственные статьи, и будучи отправленной, статья может быть изменена только уполномоченным пользователем.");  
    2 2 regGS("Article Image List", "Список картинок статьи");  
    3 3 regGS("Back to Article Image List", "Назад к списку картинок статьи");  
    4   regGS("Add new image", "Добавить новую картинку");  
    5   regGS("Add an existing image", "Добавить существующую картинку");  
      4 regGS("Add New Image", "Добавить новую картинку");  
      5 regGS("Add an Existing Image", "Добавить существующую картинку");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Дата<BR><SMALL>(гггг-мм-дд)</SMALL>");  
    7 7 regGS("Remove Image From Article", "<nobr>Удалить картинку</nobr> <nobr>из статьи</nobr>");  
  • trunk/campsite/implementation/management/priv/lang/ru/issues.php

    r3953 r4085  
    22 22 regGS("Are you sure you want to delete the issue $1?", "Вы уверены, что хотите удалить выпуск $1?");  
    23 23 regGS("Deleting issue", "Удаление выпуска");  
    24   regGS("The issue $1 has ben deleted.", "Выпуск $1 был удален.");  
      24 regGS("The issue $1 has been deleted.", "Выпуск $1 был удален.");  
    24 24 regGS("The issue $1 could not be deleted.", "Не удалось удалить выпуск $1.");  
    25 25 regGS("All sections from Issue $1 from publication $2 deleted", "Удалены все секции из выпуска $1 публикации $2");  
  • trunk/campsite/implementation/management/priv/lang/ru/localizer.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("Log Messages", "");  
    2 3 regGS("edit '$1'", "редактировать '$1'");  
    3 4 regGS("edit \"$1\"", "редактировать \"$1\"");  
  • trunk/campsite/implementation/management/priv/lang/ru/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Добавить новую картинки");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Дата (гггг-мм-дд)");  
    9 10 regGS("Used in articles", "Использована в статьях");  
    10 11 regGS("View image", "Просмотреть картинку");  
    11   regGS("Back to image archive", "Назад к архиву картинок");  
    12 12 regGS("Change image information", "Изменить информацию о картинке");  
    13 13 regGS("Changed image properties of $1", "Измененные свойства картинки $1");  
  • trunk/campsite/implementation/management/priv/lang/ru/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Название<BR><SMALL>(щелкните для просмотра выпуска)</SMALL>");  
    3 4 regGS("Delete publication $1", "Удалить публикацию $1");  
  • trunk/campsite/implementation/management/priv/lang/es/articles.php

    r3953 r4085  
    8 8 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Artículo $1 agregado a $2. $3 de $4. $5 de $6");  
    9 9 regGS("Are you sure you want to delete the article $1 ($2)?", "¿Esta seguro que quiere borrar el artículo $1 ($2)?");  
    10   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Artículo $1 ($2) borrado de $3.  $4 de $5.  $6 ($7) de $8");  
    11 10 regGS("Change article status", "Cambiar estatus de artículo");  
    12 11 regGS("Change the status of article $1 ($2) from $3 to", "Cambiar el estatus de artículo $1 ($2) de $3 a");  
    13   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Estatus de artículo $1 de $2.  $3 de $4. $5 ($6) de $7 cambiado");  
    14 12 regGS("Translate article", "Traducir artículo");  
    15   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "No tiene derechos para cambiar este artículo.  Solamente puede editar sus propios artículos y una vez enviado un artículo sólo puede ser cambiado por usuarios autorizados.");  
    16   regGS("Edit article details", "Editar detalles de artículo");  
      13 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "No tiene derechos para cambiar este artículo.  Solamente puede editar sus propios artículos y una vez enviado un artículo sólo puede ser cambiado por usuarios autorizados.");  
      14 regGS("Edit article", "Editar detalles de artículo");  
    17 15 regGS("Allow users without subscriptions to view the article", "Permitir usuarios sin suscripción a ver este artículo");  
    18 16 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "");  
  • trunk/campsite/implementation/management/priv/lang/es/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "");  
    3 3 regGS("Back to Article Image List", "");  
    4   regGS("Add new image", "Agregar nueva imagen");  
    5   regGS("Add an existing image", "");  
      4 regGS("Add New Image", "Agregar nueva imagen");  
      5 regGS("Add an Existing Image", "");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "aaaa-mm-dd");  
    7 7 regGS("Delete image $1", "Borrar imagen $1");  
  • trunk/campsite/implementation/management/priv/lang/es/issues.php

    r3953 r4085  
    29 29 regGS("Are you sure you want to delete the issue $1?", "¿Estas seguro que desea borrar la edición $1?");  
    30 30 regGS("Deleting issue", "Borrando edición");  
    31   regGS("The issue $1 has ben deleted.", "La edición $1 ha sido borrada");  
      31 regGS("The issue $1 has been deleted.", "La edición $1 ha sido borrada");  
    31 31 regGS("The issue $1 could not be deleted.", "La edición $1 no pudo ser borrada");  
    32 32 regGS("All sections from Issue $1 from publication $2 deleted", "Todas las secciones de Edición $1 de publicación $2 borradas");  
  • trunk/campsite/implementation/management/priv/lang/es/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Agregar nueva imagen");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "aaaa-mm-dd");  
    9 10 regGS("Used in articles", "");  
    10 11 regGS("View image", "Ver imagen");  
    11   regGS("Back to image archive", "");  
    12 12 regGS("Change image information", "Cambiar información de imagen");  
    13 13 regGS("Changed image properties of $1", "Cambiar propiedades de imagen $1?");  
  • trunk/campsite/implementation/management/priv/lang/es/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Nombre");  
    3 4 regGS("Delete publication $1", "Borrar publicación $1");  
  • trunk/campsite/implementation/management/priv/lang/fr/users.php

    r4037 r4085  
    5 5 regGS("Add new IP address group", "");  
    6 6 regGS("Staff management", "");  
    7   regGS("Subscribers management", "");  
      7 regGS("Subscriber management", "");  
    7 7 regGS("Edit user rights", "");  
    8 8 regGS("User Name", "");  
  • trunk/campsite/implementation/management/priv/lang/fr/languages.php

    r4037 r4085  
    36 36 regGS("Sunday", "");  
    37 37 regGS("You do not have the right to add new languages.", "");  
    38   regGS("There are $1 classes(s) left.", "");  
    39 38 regGS("There are $1 issue(s) left.", "");  
    40   regGS("There are $1 keyword(s) left.", "");  
    41 39 ?>  
  • trunk/campsite/implementation/management/priv/lang/fr/articles.php

    r4037 r4085  
    7 7 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "");  
    8 8 regGS("Are you sure you want to delete the article $1 ($2)?", "");  
    9   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "");  
    10 9 regGS("Change article status", "");  
    11 10 regGS("Change the status of article $1 ($2) from $3 to", "");  
    12   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "");  
    13 11 regGS("Translate article", "");  
    14   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
    15   regGS("Edit article details", "");  
      12 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
      13 regGS("Edit article", "");  
    16 14 regGS("Allow users without subscriptions to view the article", "");  
    17 15 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "");  
    27 25 regGS("Edit article types", "");  
    28 26 regGS("Could not save the article. It has been locked by $1 $2 hours and $3 minutes ago.", "");  
    29   regGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users.", "");  
      27 regGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.", "");  
    29 27 regGS("You do not have the right to delete articles.", "");  
    30 28 regGS("You must select an article type.", "");  
  • trunk/campsite/implementation/management/priv/lang/fr/article_images.php

    r4037 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "");  
    3 3 regGS("Back to Article Image List", "");  
    4   regGS("Add new image", "");  
    5   regGS("Add an existing image", "");  
      4 regGS("Add New Image", "");  
      5 regGS("Add an Existing Image", "");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "");  
    7 7 regGS("Remove Image From Article", "");  
  • trunk/campsite/implementation/management/priv/lang/fr/issues.php

    r4037 r4085  
    22 22 regGS("Are you sure you want to delete the issue $1?", "");  
    23 23 regGS("Deleting issue", "");  
    24   regGS("The issue $1 has ben deleted.", "");  
      24 regGS("The issue $1 has been deleted.", "");  
    24 24 regGS("The issue $1 could not be deleted.", "");  
    25 25 regGS("All sections from Issue $1 from publication $2 deleted", "");  
  • trunk/campsite/implementation/management/priv/lang/fr/localizer.php

    r4037 r4085  
    1 1 <?php  
      2 regGS("Log Messages", "");  
    2 3 regGS("edit '$1'", "");  
    3 4 regGS("edit \"$1\"", "");  
  • trunk/campsite/implementation/management/priv/lang/fr/imagearchive.php

    r4037 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "");  
    9 10 regGS("Used in articles", "");  
    10 11 regGS("View image", "");  
    11   regGS("Back to image archive", "");  
    12 12 regGS("Change image information", "");  
    13 13 regGS("Changed image properties of $1", "");  
  • trunk/campsite/implementation/management/priv/lang/fr/pub.php

    r4037 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "");  
    3 4 regGS("Delete publication $1", "");  
  • trunk/campsite/implementation/management/priv/lang/de/articles.php

    r3953 r4085  
    8 8 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Artikel $1 wurde zu $2 hinzugefügt. $3 von $4. $5 von $6");  
    9 9 regGS("Are you sure you want to delete the article $1 ($2)?", "Artikel $1 ($2) wirklich löschen?");  
    10   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Artikel $1 ($2) wurde gelöscht. $3 von $4. $5. $6 ($7) von $8");  
    11 10 regGS("Change article status", "Artikel Status ändern");  
    12 11 regGS("Change the status of article $1 ($2) from $3 to", "Status von Artikel $1 ($2) ändern von $3 auf");  
    13   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Status von Artikel $1 von $2. $3 von $4. $5 ($6) von $7 geändert.");  
    14 12 regGS("Translate article", "Artikel übersetzen.");  
    15   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Keine Berechtigung, den Artikel zu ändern.  Bearbeiten nur von eigenen Artikeln möglich. Bereits eingepflegte Artikel können nur von autorisierten BenutzerInnen verändert werden.");  
    16   regGS("Edit article details", "Artikeldetails bearbeiten");  
      13 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Keine Berechtigung, den Artikel zu ändern.  Bearbeiten nur von eigenen Artikeln möglich. Bereits eingepflegte Artikel können nur von autorisierten BenutzerInnen verändert werden.");  
      14 regGS("Edit article", "Artikeldetails bearbeiten");  
    17 15 regGS("Allow users without subscriptions to view the article", "BenutzerInnen ohne Abonoment Ansicht des Artikels erlauben");  
    18 16 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "");  
  • trunk/campsite/implementation/management/priv/lang/de/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "");  
    3 3 regGS("Back to Article Image List", "");  
    4   regGS("Add new image", "Neues Bild hinzufügen");  
    5   regGS("Add an existing image", "");  
      4 regGS("Add New Image", "Neues Bild hinzufügen");  
      5 regGS("Add an Existing Image", "");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Datum (jjjj-mm-tt)");  
    7 7 regGS("Delete image $1", "Bild $1 löschen");  
  • trunk/campsite/implementation/management/priv/lang/de/issues.php

    r3953 r4085  
    28 28 regGS("Are you sure you want to delete the issue $1?", "Ausgabe $1 wirklich löschen?");  
    29 29 regGS("Deleting issue", "Ausgabe wird gelöscht");  
    30   regGS("The issue $1 has ben deleted.", "Ausgabe $1 wurde gelöscht");  
      30 regGS("The issue $1 has been deleted.", "Ausgabe $1 wurde gelöscht");  
    30 30 regGS("The issue $1 could not be deleted.", "Ausgabe $1 konnte nicht gelöscht werden");  
    31 31 regGS("All sections from Issue $1 from publication $2 deleted", "Alle Rubriken in Ausgabe $1 der Publikation $2 wurden gelöscht");  
  • trunk/campsite/implementation/management/priv/lang/de/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Neues Bild hinzufügen");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Datum (jjjj-mm-tt)");  
    9 10 regGS("Used in articles", "");  
    10 11 regGS("View image", "Bild betrachten");  
    11   regGS("Back to image archive", "");  
    12 12 regGS("Change image information", "Bildinformation ändern");  
    13 13 regGS("Changed image properties of $1", "Bildeigenschaften von $1 geändert");  
  • trunk/campsite/implementation/management/priv/lang/de/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Name");  
    3 4 regGS("Delete publication $1", "Publikation $1 löschen");  
  • trunk/campsite/implementation/management/priv/lang/hr/articles.php

    r3953 r4085  
    8 8 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Članak $1 dodan je $2. $3 od $4. $5 od $6");  
    9 9 regGS("Are you sure you want to delete the article $1 ($2)?", "Jeste li sigurni da želite izbrisati članak $1 ($2)?");  
    10   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Članak $1 ($2) izbrisan iz $3. $4 iz $5. $6 ($7) od $8:");  
    11 10 regGS("Change article status", "Promijeni status članka");  
    12 11 regGS("Change the status of article $1 ($2) from $3 to", "Promijeni status članka $1 ($2) iz $3 u:");  
    13   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Članak $1 status iz $2. $3 iz $4. $5 ($6) od $7 promjenjeni:");  
    14 12 regGS("Translate article", "Prevedi članak");  
    15   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Nemate pravo mijenjati ovaj članak. Možete urediti samo svoje članke, a predane članke mogu mijenjati samo autorizirani korisnici.");  
    16   regGS("Edit article details", "Uredi detalje članka");  
      13 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Nemate pravo mijenjati ovaj članak. Možete urediti samo svoje članke, a predane članke mogu mijenjati samo autorizirani korisnici.");  
      14 regGS("Edit article", "Uredi detalje članka");  
    17 15 regGS("Allow users without subscriptions to view the article", "Dozvoli korisniku bez pretplate da vidi ovaj članak");  
    18 16 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "");  
  • trunk/campsite/implementation/management/priv/lang/hr/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "");  
    3 3 regGS("Back to Article Image List", "");  
    4   regGS("Add new image", "Dodaj novu sliku");  
    5   regGS("Add an existing image", "");  
      4 regGS("Add New Image", "Dodaj novu sliku");  
      5 regGS("Add an Existing Image", "");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Datum <br><small>(gggg-mm-dd)</small>:");  
    7 7 regGS("Delete image $1", "Izbriši sliku $1:");  
  • trunk/campsite/implementation/management/priv/lang/hr/issues.php

    r3953 r4085  
    28 28 regGS("Are you sure you want to delete the issue $1?", "Da li ste sigurni da želite izbrisati izdanje $1?");  
    29 29 regGS("Deleting issue", "Brisanje izdanja");  
    30   regGS("The issue $1 has ben deleted.", "Izdanje $1 je izbrisano.");  
      30 regGS("The issue $1 has been deleted.", "Izdanje $1 je izbrisano.");  
    30 30 regGS("The issue $1 could not be deleted.", "Izdanje $1 se ne može izbrisati.");  
    31 31 regGS("All sections from Issue $1 from publication $2 deleted", "Sve rubrike iz izdanja $1 u publikaciji $2 su izbrisane");  
  • trunk/campsite/implementation/management/priv/lang/hr/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Dodaj novu sliku");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Datum (gggg-mm-dd)");  
    9 10 regGS("Used in articles", "");  
    10 11 regGS("View image", "Vidi sliku");  
    11   regGS("Back to image archive", "");  
    12 12 regGS("Change image information", "Promijeni podatke o slici");  
    13 13 regGS("Changed image properties of $1", "Promijeni postavke za sliku $1");  
  • trunk/campsite/implementation/management/priv/lang/hr/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Ime<br><small>(kliknite da vidite izdanje)</small>");  
    3 4 regGS("Delete publication $1", "Izbiši publikaciju $1");  
  • trunk/campsite/implementation/management/priv/lang/sh/users.php

    r3953 r4085  
    5 5 regGS("Add new IP address group", "Dodajte novu korisničku grupu zasnovanu na IP adresi");  
    6 6 regGS("Staff management", "Upravljanje saradničkim nalozima");  
    7   regGS("Subscribers management", "Upravljanje pretplatničkim nalozima");  
      7 regGS("Subscriber management", "Upravljanje pretplatničkim nalozima");  
    7 7 regGS("Edit user rights", "Prikaži korisnička prava");  
    8 8 regGS("User Name", "Korisničko ime");  
  • trunk/campsite/implementation/management/priv/lang/sh/languages.php

    r3953 r4085  
    36 36 regGS("Sunday", "nedelja");  
    37 37 regGS("You do not have the right to add new languages.", "Nemate pravo da dodajete nove jezike");  
    38   regGS("There are $1 classes(s) left.", "Preostalo je $1 klasa.");  
    39 38 regGS("There are $1 issue(s) left.", "Preostalo je $1 izdanja.");  
    40   regGS("There are $1 keyword(s) left.", "Preostalo je $1 ključnih reči.");  
    41 39 regGS("The language $1 has been successfuly added.", "Jezik $1 uspešno je dodat");  
    42 40 regGS("Please check if a language with the same name does not already exist.", "Proverite da li jezik sa istim imenom već ne postoji");  
  • trunk/campsite/implementation/management/priv/lang/sh/articles.php

    r3953 r4085  
    7 7 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Članak $1 je dodat u $2. $3 iz $4. $5 od $6");  
    8 8 regGS("Are you sure you want to delete the article $1 ($2)?", "Da li ste sigurni da želite da obrišete članak $1 ($2)?");  
    9   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Članak $1 ($2) je obrisan iz $3. $4 iz $5. 46 ($7) od $8");  
    10 9 regGS("Change article status", "Promeni status članka");  
    11 10 regGS("Change the status of article $1 ($2) from $3 to", "Promeni status članka $1 ($2) iz $3 u");  
    12   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Status članka $1 iz $2. $3 iz $4. $5 ($6) od $7 promenjen");  
    13 11 regGS("Translate article", "Prevedi članak");  
    14   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Nemate pravo da menjate članak. Možete pregledati jedino sopstvene članke, a jednom prijavljeni članak može biti menjan samo od strane ovlašćenih korisnika");  
    15   regGS("Edit article details", "Prikaz detalja članka");  
      12 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Nemate pravo da menjate članak. Možete pregledati jedino sopstvene članke, a jednom prijavljeni članak može biti menjan samo od strane ovlašćenih korisnika");  
      13 regGS("Edit article", "Prikaz detalja članka");  
    16 14 regGS("Allow users without subscriptions to view the article", "Dozvoli korisnicima bez pretplate da čitaju članak");  
    17 15 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "Članak je zaključao $1 ($2) pre $3 časova i $4 minuta. ");  
    27 25 regGS("Edit article types", "Prikaži tipove članaka");  
    28 26 regGS("Could not save the article. It has been locked by $1 $2 hours and $3 minutes ago.", "Članak ne može biti snimljen. Zaključan je od strane $1 pre $2časova i $3 minuta.");  
    29   regGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users.", "Nemate pravo da menajte status članka. Predatom članku status može promeniti samo ovlašćeni korisnik.");  
      27 regGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.", "Nemate pravo da menajte status članka. Predatom članku status može promeniti samo ovlašćeni korisnik.");  
    29 27 regGS("You do not have the right to delete articles.", "Nemate pravo da brišete članke.");  
    30 28 regGS("You must select an article type.", "Morate izabrati tip članka.");  
  • trunk/campsite/implementation/management/priv/lang/sh/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Nemate pravo da menjate članak. Možete menjati samo svoje članke, a predatim člancima status može promeniti samo ovlašćeni korsnik.");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Nemate pravo da menjate članak. Možete menjati samo svoje članke, a predatim člancima status može promeniti samo ovlašćeni korsnik.");  
    2 2 regGS("Article Image List", "Lista slika u članku");  
    3 3 regGS("Back to Article Image List", "Nazad na listu slika u članku");  
    4   regGS("Add new image", "Dodaj novu sliku");  
    5   regGS("Add an existing image", "Dodaj postojeću sliku");  
      4 regGS("Add New Image", "Dodaj novu sliku");  
      5 regGS("Add an Existing Image", "Dodaj postojeću sliku");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Datum<br><small>(gggg-mm-dd)</small>");  
    7 7 regGS("Remove Image From Article", "Ukloni sliku iz članka");  
    27 27 regGS("Are you sure you want to delete the image '$1'?", "Da li ste sigurni da želite da obrišete sliku $1?");  
    28 28 regGS("Unlink image $1", "Ukloni vezu slike $1");  
    29   regGS("Are you sure you want to remove the image \\'$1\\' from the article?", "Da li ste sigurni da želite da uklonite sliku \\'$1\\' iz članka?");  
    30 29 ?>  
  • trunk/campsite/implementation/management/priv/lang/sh/issues.php

    r3953 r4085  
    22 22 regGS("Are you sure you want to delete the issue $1?", "Sigurni ste da želite da obrišete izdanje $1?");  
    23 23 regGS("Deleting issue", "Brisanje izdanja");  
    24   regGS("The issue $1 has ben deleted.", "Izdanje $1 je izbrisano.");  
      24 regGS("The issue $1 has been deleted.", "Izdanje $1 je izbrisano.");  
    24 24 regGS("The issue $1 could not be deleted.", "Izdanje $1 ne može biti izbrisano.");  
    25 25 regGS("All sections from Issue $1 from publication $2 deleted", "Sve rubrike izdanja $1 iz publikacije $2 su izbrisane");  
  • trunk/campsite/implementation/management/priv/lang/sh/localizer.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("Log Messages", "");  
    2 3 regGS("edit '$1'", "prikaži '$1'");  
    3 4 regGS("edit \"$1\"", "prikaži \"$1\"");  
  • trunk/campsite/implementation/management/priv/lang/sh/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Dodaj novu sliku");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Datum (gggg-mm-dd)");  
    9 10 regGS("Used in articles", "Koristi se u člancima");  
    10 11 regGS("View image", "Prikaži sliku");  
    11   regGS("Back to image archive", "Nazad na foto arhivu");  
    12 12 regGS("Change image information", "Promeni podatke o slici");  
    13 13 regGS("Changed image properties of $1", "Promeni osobine slike $1");  
  • trunk/campsite/implementation/management/priv/lang/sh/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Ime<br><small>(kliknite za pregled izdanja)</small>");  
    3 4 regGS("Delete publication $1", "Obriši publikaciju $1");  
  • trunk/campsite/implementation/management/priv/lang/cz/articles.php

    r3953 r4085  
    7 7 regGS("Article $1 added to $2. $3 from $4. $5 of $6", "Článek $1 byl přidán do $2. $3 z $4. $5 z $6");  
    8 8 regGS("Are you sure you want to delete the article $1 ($2)?", "Určitě chcete smazat článek $1 ($2)?");  
    9   regGS("Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8", "Článek $1 ($2) byl smazán z $3. 4$ z $5. $6 ($7) z $8");  
    10 9 regGS("Change article status", "Změnit stav článku");  
    11 10 regGS("Change the status of article $1 ($2) from $3 to", "Změnit stav článku $1 ($2) z $3");  
    12   regGS("Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed", "Stav článku $1z $2. $3 z $4. $5 ($6) z $7 byl změněn");  
    13 11 regGS("Translate article", "Překlat článku");  
    14   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "Nemáte právo změnit tento článek. Můžete pouze editova své vlastní články. Podané články mohou být změněny pouze autorizovanými uživateli.");  
    15   regGS("Edit article details", "Editovat detaily článku");  
      12 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "Nemáte právo změnit tento článek. Můžete pouze editova své vlastní články. Podané články mohou být změněny pouze autorizovanými uživateli.");  
      13 regGS("Edit article", "Editovat detaily článku");  
    16 14 regGS("Allow users without subscriptions to view the article", "Povolit náhled článku uživatelům bez předplatného");  
    17 15 regGS("The article has been locked by $1 ($2) $3 hour(s) and $4 minute(s) ago.", "");  
    27 25 regGS("Edit article types", "");  
    28 26 regGS("Could not save the article. It has been locked by $1 $2 hours and $3 minutes ago.", "");  
    29   regGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users.", "");  
      27 regGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.", "");  
    29 27 regGS("You do not have the right to delete articles.", "");  
    30 28 regGS("You must select an article type.", "");  
  • trunk/campsite/implementation/management/priv/lang/cz/article_images.php

    r3953 r4085  
    1 1 <?php  
    2   regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.", "");  
      2 regGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.", "");  
    2 2 regGS("Article Image List", "");  
    3 3 regGS("Back to Article Image List", "");  
    4   regGS("Add new image", "Přidat obrázek");  
    5   regGS("Add an existing image", "");  
      4 regGS("Add New Image", "Přidat obrázek");  
      5 regGS("Add an Existing Image", "");  
    6 6 regGS("Date<BR><SMALL>(yyyy-mm-dd)</SMALL>", "Datum (rrrr-mm-dd)");  
    7 7 regGS("Delete image $1", "Stazat obrázek $1");  
  • trunk/campsite/implementation/management/priv/lang/cz/issues.php

    r3953 r4085  
    28 28 regGS("Are you sure you want to delete the issue $1?", "Určitě chcete smazat vydání $1?");  
    29 29 regGS("Deleting issue", "Mazaní vydání");  
    30   regGS("The issue $1 has ben deleted.", "Vydání $1 bylo smazáno");  
      30 regGS("The issue $1 has been deleted.", "Vydání $1 bylo smazáno");  
    30 30 regGS("The issue $1 could not be deleted.", "Vydání $1 nemohlo být smazáno");  
    31 31 regGS("All sections from Issue $1 from publication $2 deleted", "Všechny rubriky z vydání $1 v publikaci $2 byly smazány");  
  • trunk/campsite/implementation/management/priv/lang/cz/imagearchive.php

    r3953 r4085  
    1 1 <?php  
      2 regGS("You must select an image file to upload.", "");  
    2 3 regGS("Add new image", "Přidat obrázek");  
    3 4 regGS("Date <SMALL>(yyyy-mm-dd)</SMALL>", "Datum (rrrr-mm-dd)");  
    9 10 regGS("Used in articles", "");  
    10 11 regGS("View image", "Náhled obrázku");  
    11   regGS("Back to image archive", "");  
    12 12 regGS("Change image information", "Změnit informace obrázku");  
    13 13 regGS("Changed image properties of $1", "Změnit vlastnosti obrázku");  
  • trunk/campsite/implementation/management/priv/lang/cz/pub.php

    r3985 r4085  
    1 1 <?php  
      2 regGS("Go To Issues", "");  
    2 3 regGS("Name<BR><SMALL>(click to see issues)</SMALL>", "Název publikace (klikněte pro náhled vydání)");  
    3 4 regGS("Delete publication $1", "Smazat publikaci $1");  
  • trunk/campsite/implementation/management/priv/lib_campsite.php

    r4077 r4085  
    116 116  
    117 117  
    118   /**  
    119    * Create an HTML OPTION element.  
    120    *  
    121    * @param string $p_value  
    122    * @param string $p_selectedValue  
    123    * @param string $p_printValue  
    124    * @return void  
    125    */  
    126   function pcomboVar($p_value, $p_selectedValue, $p_printValue)  
    127   {  
    128       print '<OPTION VALUE="'.htmlspecialchars($p_value, ENT_QUOTES).'"';  
    129       if (!strcmp($p_value, $p_selectedValue)) {  
    130           print ' SELECTED';  
    131       }  
    132       print '>'.htmlspecialchars($p_printValue);  
    133   } // fn pcombovar  
    134    
    135    
    136 118 /**  
    137 119  * An alias for "print()".  
     
    147 129 /**  
    148 130  * Load the global and local language files.  
    149    * @param string $p_path  
    150 131  * @param string $p_name  
    151 132  * @return void  
    152 133  */  
    153   function selectLanguageFile($p_name)  
      134 function camp_load_language($p_name)  
    153 134 {  
    154 135     require_once('localizer/Localizer.php');  
     
    159 140     }  
    160 141     Localizer::LoadLanguageFiles($p_name, $langCode);  
    161   } // fn selectLanguageFile  
      142 } // fn camp_load_language  
    161 142  
    162 143  
    163   function limitchars($text, $lim, $break, $tail)  
    164   {  
    165       //  $text = split("$break", $text);  
    166       // If you want this function case insensitive  
    167       // replace above line with these two lines  
    168       $text=preg_replace("/$break/i", strtolower($break), $text);  
    169       $text = split(strtolower("$break"), $text);  
    170       if (strlen(implode("$break", $text)) >= $lim) {  
    171           $i = 0;  
    172           $add_str = "";  
    173           while($i <= count($text)) {  
    174               $add_str = $text[$i];  
    175               $out[] = $add_str;  
    176               if(strlen(implode("$break", $out)) >= $lim - strlen($break) - strlen($add_str)) {  
    177                   break;  
    178               }  
    179               $add_str = "";  
    180               $i++;  
    181           }  
    182           $text = implode("$break", $out);  
    183           if (substr($text, 0, -strlen($break)) == $break) {  
    184               $text = substr($text, 0, -strlen($break));  
    185           }  
    186           $text = "$text$tail";  
    187       }  
    188       else {  
    189           $text=implode("$break", $text);  
    190       }  
    191       return $text;  
    192   } // fn limitchars  
      144 /**  
      145  * Split the given text into something.  
      146  * @return string  
      147  */  
      148 //function camp_limit_chars($p_text, $p_limit, $p_break, $p_tail)  
      149 //{  
      150 //  $p_text = preg_replace("/$p_break/i", strtolower($p_break), $p_text);  
      151 //  $p_text = split(strtolower("$p_break"), $p_text);  
      152 //  if (strlen(implode("$p_break", $p_text)) >= $p_limit) {  
      153 //      $i = 0;  
      154 //      $add_str = "";  
      155 //      while($i <= count($p_text)) {  
      156 //          $add_str = $p_text[$i];  
      157 //          $out[] = $add_str;  
      158 //          if(strlen(implode("$p_break", $out)) >= $p_limit - strlen($p_break) - strlen($add_str)) {  
      159 //              break;  
      160 //          }  
      161 //          $add_str = "";  
      162 //          $i++;  
      163 //      }  
      164 //      $p_text = implode("$p_break", $out);  
      165 //      if (substr($p_text, 0, -strlen($p_break)) == $p_break) {  
      166 //          $p_text = substr($p_text, 0, -strlen($p_break));  
      167 //      }  
      168 //      $p_text = "$p_text$p_tail";  
      169 //  }  
      170 //  else {  
      171 //      $p_text=implode("$p_break", $p_text);  
      172 //  }  
      173 //  return $p_text;  
      174 //} // fn camp_limit_chars  
    193 175  
    194 176  
    210 192  
    211 193  
      194 /**  
      195  * Get the first element from the given array, but do not modify  
      196  * the array the way array_pop() does.  
      197  * @param array $p_array  
      198  * @return mixed  
      199  */  
      200 function camp_array_peek($p_array)  
      201 {  
      202     reset($p_array);  
      203     list($key, $element) = each($p_array);  
      204     return $element;  
      205 } // fn camp_array_peek  
      206  
      207  
      208 /**  
      209  *  
      210  * @param string $p_name  
      211  * @param mixed $p_defaultValue  
      212  * @return mixed  
      213  */  
      214 function camp_persistant_var($p_name, $p_defaultValue)  
      215 {  
      216     // Use the REQUEST variable if it is set.  
      217     if (isset($_REQUEST[$p_name])) {  
      218         $_SESSION[$p_name] = $_REQUEST[$p_name];  
      219     }  
      220     elseif (!isset($_SESSION[$p_name])) {  
      221         $_SESSION[$p_name] = $p_defaultValue;  
      222     }  
      223     return $_SESSION[$p_name];  
      224 }  
      225  
      226  
    212 227 if (file_exists($_SERVER['DOCUMENT_ROOT']."/$ADMIN_DIR/modules/admin/priv_functions.php")) {  
    213 228     include ($_SERVER['DOCUMENT_ROOT']."/$ADMIN_DIR/modules/admin/priv_functions.php");  
  • trunk/campsite/implementation/management/priv/imagearchive/edit.php

    r4054 r4085  
    130 130     <?php  
    131 131     $color = 0;  
    132       $previousArticleId = -1;  
      132     $previousArticleNumber = -1;  
    132 132     foreach ($articles as $article) {  
    133 133         echo '<tr ';  
     
    141 141         }  
    142 142         echo '>';  
    143           if ($article->getArticleId() == $previousArticleId) {  
      143         if ($article->getArticleNumber() == $previousArticleNumber) {  
    143 143             echo '<td style="padding-left: 20px;">';  
    144 144         }  
    147 147             echo '<td>';  
    148 148         }  
    149           echo "<a href=\"/$ADMIN/articles/edit.php?Pub=".$article->getPublicationId().'&Issue='.$article->getIssueId().'&Section='.$article->getSectionId().'&Article='.$article->getArticleId().'&Language='.$article->getLanguageId().'&sLanguage='.$article->getLanguageId().'">'.htmlspecialchars($article->getTitle()).'</a></td></tr>';  
    150           $previousArticleId = $article->getArticleId();  
      149         echo "<a href=\"/$ADMIN/articles/edit.php?Pub=".$article->getPublicationId().'&Issue='.$article->getIssueNumber().'&Section='.$article->getSectionNumber().'&Article='.$article->getArticleNumber().'&Language='.$article->getLanguageId().'&sLanguage='.$article->getLanguageId().'">'.htmlspecialchars($article->getTitle()).'</a></td></tr>';  
      150         $previousArticleNumber = $article->getArticleNumber();  
    151 151     }  
    152 152     ?>  
  • trunk/campsite/implementation/management/priv/localizer/translate.php

    r3958 r4085  
    95 95     $mapPrefixToDisplay["globals"] = getGS("Globals");  
    96 96     $mapPrefixToDisplay["home"] = getGS("Home");  
      97     $mapPrefixToDisplay["api"] = getGS("Log Messages");  
    97 98     $mapPrefixToDisplay["pub"] = getGS("Publications");  
    98 99     $mapPrefixToDisplay["issues"] = getGS("Issues");  
  • trunk/campsite/implementation/management/priv/localizer/LocalizerConfig.php

    r4078 r4085  
    34 34 // The top-level directory to the set of directories  
    35 35 // that need translation files.  
    36   $g_localizerConfig['BASE_DIR'] = $_SERVER['DOCUMENT_ROOT'].'/admin-files';  
      36 $g_localizerConfig['BASE_DIR'] = $_SERVER['DOCUMENT_ROOT'];  
    36 36  
    37 37 // The top-level directory to the set of directories  
    63 63 $mapPrefixToDir[""] = null;  
    64 64 $mapPrefixToDir["globals"] = null;  
    65   $mapPrefixToDir["home"] = "/";  
    66   $mapPrefixToDir["pub"] = "/pub";  
    67   $mapPrefixToDir["issues"] = "/issues";  
    68   $mapPrefixToDir["sections"] = "/sections";  
    69   $mapPrefixToDir["articles"] = "/articles";  
    70   $mapPrefixToDir["article_images"] = "/articles/images";  
    71   $mapPrefixToDir["article_topics"] = "/articles/topics";  
    72   $mapPrefixToDir["imagearchive"] = "/imagearchive";  
    73   $mapPrefixToDir["templates"] = "/templates";  
    74   $mapPrefixToDir["article_types"] = "/article_types";  
    75   $mapPrefixToDir["article_type_fields"] = "/article_types/fields";  
    76   $mapPrefixToDir["topics"] = "/topics";  
    77   $mapPrefixToDir["languages"] = "/languages";  
    78   $mapPrefixToDir["country"] = "/country";  
    79   $mapPrefixToDir["localizer"] = "/localizer";  
    80   $mapPrefixToDir["logs"] = "/logs";  
    81   $mapPrefixToDir["users"] = "/users";  
    82   $mapPrefixToDir["user_subscriptions"] = "/users/subscriptions";  
    83   $mapPrefixToDir["user_subscription_sections"] = "/users/subscriptions/sections";  
    84   $mapPrefixToDir["user_types"] = "/user_types";  
      65 $mapPrefixToDir["home"] = "/admin-files/";  
      66 $mapPrefixToDir["api"] = "/classes/";  
      67 $mapPrefixToDir["pub"] = "/admin-files/pub";  
      68 $mapPrefixToDir["issues"] = "/admin-files/issues";  
      69 $mapPrefixToDir["sections"] = "/admin-files/sections";  
      70 $mapPrefixToDir["articles"] = "/admin-files/articles";  
      71 $mapPrefixToDir["article_images"] = "/admin-files/articles/images";  
      72 $mapPrefixToDir["article_topics"] = "/admin-files/articles/topics";  
      73 $mapPrefixToDir["imagearchive"] = "/admin-files/imagearchive";  
      74 $mapPrefixToDir["templates"] = "/admin-files/templates";  
      75 $mapPrefixToDir["article_types"] = "/admin-files/article_types";  
      76 $mapPrefixToDir["article_type_fields"] = "/admin-files/article_types/fields";  
      77 $mapPrefixToDir["topics"] = "/admin-files/topics";  
      78 $mapPrefixToDir["languages"] = "/admin-files/languages";  
      79 $mapPrefixToDir["country"] = "/admin-files/country";  
      80 $mapPrefixToDir["localizer"] = "/admin-files/localizer";  
      81 $mapPrefixToDir["logs"] = "/admin-files/logs";  
      82 $mapPrefixToDir["users"] = "/admin-files/users";  
      83 $mapPrefixToDir["user_subscriptions"] = "/admin-files/users/subscriptions";  
      84 $mapPrefixToDir["user_subscription_sections"] = "/admin-files/users/subscriptions/sections";  
      85 $mapPrefixToDir["user_types"] = "/admin-files/user_types";  
    85 86 $g_localizerConfig["MAP_PREFIX_TO_DIR"] = $mapPrefixToDir;  
    86 87 unset($mapPrefixToDir);  
  • trunk/campsite/implementation/management/priv/pub/do_edit.php

    r4077 r4085  
    63 63 //  else {  
    64 64 //      $errorMsgs[] = getGS('The publication information could not be updated.')  
    65   //                    .' '.getGS('Please check if another publication with the same or the same site name does not already exist.');  
      65 //                    .' '.getGS('Please check if another publication with the same name or the same site name does not already exist.');  
    65 65 //  }  
    66 66 }  
  • trunk/campsite/implementation/management/priv/pub/deftime.php

    r3985 r4085  
    25 25 ?>     
    26 26 <p>  
    27   <TABLE>  
      27 <TABLE class="action_buttons">  
    27 27 <TR>  
    28       <TD><TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1"><TR><TD><A HREF="countryadd.php?Pub=<?php p($Pub); ?>&Language=<?php p($Language); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD><TD><A HREF="countryadd.php?Pub=<?php p($Pub); ?>&Language=<?php p($Language); ?>" ><B><?php  putGS("Add new country"); ?></B></A></TD></TR></TABLE></TD>  
      28     <TD><A HREF="countryadd.php?Pub=<?php p($Pub); ?>&Language=<?php p($Language); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD>  
      29     <TD><A HREF="countryadd.php?Pub=<?php p($Pub); ?>&Language=<?php p($Language); ?>" ><B><?php  putGS("Add new country"); ?></B></A></TD>  
    29 30 </TR>  
    30 31 </TABLE>  
    40 41 </TR>  
    41 42 <?php   
      43 $color = 0;  
    42 44 foreach ($defaultTimes as $time) {  
    43 45     $country =& new Country($time->getCountryCode(), $Language);  
  • trunk/campsite/implementation/management/priv/pub/aliases.php

    r4054 r4085  
    16 16      
    17 17 camp_html_content_top(getGS("Publication Aliases"), array("Pub" => $publicationObj));  
    18   ?>  
    19 18  
    20   <?php if ($User->hasPermission("ManagePub")) { ?>  
    21   <TABLE>  
      19 if ($User->hasPermission("ManagePub")) { ?>  
      20 <p>  
      21 <TABLE class="action_buttons">  
    22 22 <TR>  
    23       <TD><TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1"><TR><TD><A HREF="add_alias.php?Pub=<?php p($Pub); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD><TD><A HREF="add_alias.php?Pub=<?php  p($Pub); ?>" ><B><?php  putGS("Add new alias"); ?></B></A></TD></TR></TABLE></TD>  
      23     <TD><A HREF="add_alias.php?Pub=<?php p($Pub); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD>  
      24     <TD><A HREF="add_alias.php?Pub=<?php  p($Pub); ?>" ><B><?php  putGS("Add new alias"); ?></B></A></TD>  
    24 25 </TR>  
    25 26 </TABLE>  
  • trunk/campsite/implementation/management/priv/pub/edit.php

    r4054 r4085  
    34 34  
    35 35 echo camp_html_content_top(getGS("Configure publication"), array("Pub" => $publicationObj));  
      36 ?>  
      37 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1" class="action_buttons" style="padding-top: 5px;">  
      38 <TR>  
      39     <TD><A HREF="/<?php echo $ADMIN; ?>/issues/?Pub=<?php  p($Pub); ?>"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/go_to.png" BORDER="0"></A></TD>  
      40     <TD><A HREF="/<?php echo $ADMIN; ?>/issues/?Pub=<?php  p($Pub); ?>"><B><?php  putGS("Go To Issues"); ?></B></A></TD>  
      41 </TR>  
      42 </TABLE>  
    36 43  
      44 <?php  
      45 if ($User->hasPermission("DeletePub")) {  
    37 46 ?>  
    38 47 <P>  
      48 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1" class="action_buttons">  
      49 <TR>  
      50     <TD><A HREF="do_del.php?Pub=<?php p($Pub); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the publication $1?', htmlspecialchars($publicationObj->getName())); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0"></A></TD>  
      51     <TD><A HREF="do_del.php?Pub=<?php p($Pub); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the publication $1?', htmlspecialchars($publicationObj->getName())); ?>');"><B><?php  putGS("Delete"); ?></B></A></TD>  
      52 </TR>  
      53 </TABLE>  
      54 <?php } ?>  
      55  
      56 <P>  
    39 57 <FORM NAME="dialog" METHOD="POST" ACTION="do_edit.php"  >  
    40 58 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" CLASS="table_input">  
     
    58 76         <?php  
    59 77             foreach ($aliases as $alias) {  
    60                   pcomboVar($alias->getId(), $publicationObj->getDefaultAliasId(), $alias->getName());         
      78                 camp_html_select_option($alias->getId(), $publicationObj->getDefaultAliasId(), $alias->getName());       
    60 78             }  
    61 79         ?>  
     
    71 89     <?php  
    72 90     foreach ($languages as $language) {  
    73           pcomboVar($language->getLanguageId(), $publicationObj->getDefaultLanguageId(), $language->getNativeName());  
      91         camp_html_select_option($language->getLanguageId(), $publicationObj->getDefaultLanguageId(), $language->getNativeName());  
    73 91     }  
    74 92     ?>  
     
    84 102     <?php  
    85 103         foreach ($urlTypes as $urlType) {  
    86               pcomboVar($urlType->getId(), $publicationObj->getUrlTypeId(), $urlType->getName());  
      104             camp_html_select_option($urlType->getId(), $publicationObj->getUrlTypeId(), $urlType->getName());  
    86 104         }  
    87 105     ?>  
    105 123     <?php  
    106 124     foreach ($timeUnits as $timeUnit) {  
    107           pcomboVar($timeUnit->getUnit(), $publicationObj->getTimeUnit(), $timeUnit->getName());  
      125         camp_html_select_option($timeUnit->getUnit(), $publicationObj->getTimeUnit(), $timeUnit->getName());  
    107 125     }  
    108 126     ?>  
  • trunk/campsite/implementation/management/priv/pub/add.php

    r4054 r4085  
    55 55     <?php  
    56 56     foreach ($languages as $language) {  
    57           pcomboVar($language->getLanguageId(), $defaultLanguage->getLanguageId(), $language->getNativeName());  
      57         camp_html_select_option($language->getLanguageId(), $defaultLanguage->getLanguageId(), $language->getNativeName());  
    57 57     }  
    58 58     ?>      </SELECT>  
     
    66 66     <?php  
    67 67     foreach ($urlTypes as $urlType) {  
    68           pcomboVar($urlType->getId(), 0, $urlType->getName());  
      68         camp_html_select_option($urlType->getId(), 0, $urlType->getName());  
    68 68     }  
    69 69     ?>  
    87 87     <?php  
    88 88     foreach ($timeUnits as $timeUnit) {  
    89           pcomboVar($timeUnit->getUnit(), 0, $timeUnit->getName());         
      89         camp_html_select_option($timeUnit->getUnit(), 0, $timeUnit->getName());       
    89 89     }  
    90 90     ?>       
  • trunk/campsite/implementation/management/priv/sections/do_add.php

    r4077 r4085  
    73 73             $cName, $Issue, $issueObj->getName(), $issueObj->getLanguageName(), $publicationObj->getName());  
    74 74         Log::Message($logtext, $User->getUserName(), 21);  
    75           header("Location: edit.php?Pub=$Pub&Issue=$Issue&Language=$Language&Section=".$newSection->getSectionId());  
      75         header("Location: edit.php?Pub=$Pub&Issue=$Issue&Language=$Language&Section=".$newSection->getSectionNumber());  
    75 75         exit;  
    76 76     }  
  • trunk/campsite/implementation/management/priv/sections/duplicate.php

    r4054 r4085  
    120 120  
    121 121 <P>  
    122   <CENTER>  
    123   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" ALIGN="CENTER" class="table_input" width="600px" style="padding-top: 10px; padding-bottom: 10px; padding-left: 40px; padding-right: 40px;">  
      122 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" class="table_input" style="padding-top: 10px; padding-bottom: 10px; padding-left: 20px; padding-right: 20px;">  
    124 123 <tr>  
    125 124 <td>  
     
    180 179         foreach ($allIssues as $tmpIssue) {  
    181 180             ?>  
    182               <option value="<?php p($tmpIssue->getIssueId().'_'.$tmpIssue->getLanguageId()); ?>"  
      181             <option value="<?php p($tmpIssue->getIssueNumber().'_'.$tmpIssue->getLanguageId()); ?>"  
    182 181             <?php  
    183               if (($tmpIssue->getIssueId().'_'.$tmpIssue->getLanguageId()) == $DestIssueInput) {  
      182             if (($tmpIssue->getIssueNumber().'_'.$tmpIssue->getLanguageId()) == $DestIssueInput) {  
    183 182                 ?>selected<?php  
    184 183             }  
    241 240         foreach ($allSections as $tmpSection) {  
    242 241             ?>  
    243               <option value="<?php p($tmpSection->getSectionId());?>"><?php p(htmlspecialchars($tmpSection->getName())); ?></option>  
      242             <option value="<?php p($tmpSection->getSectionNumber());?>"><?php p(htmlspecialchars($tmpSection->getName())); ?></option>  
    243 242             <?php  
    244 243         }  
  • trunk/campsite/implementation/management/priv/sections/add_article.php

    r4077 r4085  
    68 68     <TR <?php  if ($color) { $color=0; ?>class="list_row_even"<?php  } else { $color=1; ?>class="list_row_odd"<?php  } ?>>  
    69 69         <TD ALIGN="RIGHT">  
    70               <?php p($section->getSectionId()); ?>  
      70             <?php p($section->getSectionNumber()); ?>  
    70 70         </TD>  
    71 71         <TD >  
    72               <A HREF="/<?php p($ADMIN); ?>/articles/add.php?Pub=<?php p($Pub); ?>&Issue=<?php  p($section->getIssueId()); ?>&Section=<?php p($section->getSectionId()); ?>&Language=<?php  p($section->getLanguageId()); ?>&Wiz=1"><?php p(htmlspecialchars($section->getName())); ?></A>  
      72             <A HREF="/<?php p($ADMIN); ?>/articles/add.php?Pub=<?php p($Pub); ?>&Issue=<?php  p($section->getIssueNumber()); ?>&Section=<?php p($section->getSectionNumber()); ?>&Language=<?php  p($section->getLanguageId()); ?>&Wiz=1"><?php p(htmlspecialchars($section->getName())); ?></A>  
    72 72         </TD>  
    73 73     </TR>  
  • trunk/campsite/implementation/management/priv/sections/do_duplicate.php

    r4054 r4085  
    102 102     } else {  
    103 103         if ($created) { ?>   
    104             <?php  putGS('Section $1 has been duplicated to $2. $3 of $4', '<B>'.$srcSectionObj->getName().'</B>', '<B>'.$dstSectionObj->getIssueId().'</B>', '<B>'.$dstIssueObj->getName().' ('.$dstIssueObj->getLanguageName().')</B>', '<B>'.$dstPublicationObj->getName().'</B>'); ?>  
      104           <?php  putGS('Section $1 has been duplicated to $2. $3 of $4', '<B>'.$srcSectionObj->getName().'</B>', '<B>'.$dstSectionObj->getIssueNumber().'</B>', '<B>'.$dstIssueObj->getName().' ('.$dstIssueObj->getLanguageName().')</B>', '<B>'.$dstPublicationObj->getName().'</B>'); ?>  
    104 104           <?php   
    105 105         } else { ?>  
    117 117                 <tr>  
    118 118                     <td>  
    119                          <b><a href="/<?php echo $ADMIN; ?>/articles/?Pub=<?php  p($dstSectionObj->getPublicationId()); ?>&Issue=<?php  p($dstSectionObj->getIssueId()); ?>&Section=<?php  p($dstSectionObj->getSectionId()); ?>&Language=<?php p($dstSectionObj->getLanguageId()); ?>"><?php putGS("Go to new section"); ?></a></b>  
      119                        <b><a href="/<?php echo $ADMIN; ?>/articles/?Pub=<?php  p($dstSectionObj->getPublicationId()); ?>&Issue=<?php  p($dstSectionObj->getIssueNumber()); ?>&Section=<?php  p($dstSectionObj->getSectionNumber()); ?>&Language=<?php p($dstSectionObj->getLanguageId()); ?>"><?php putGS("Go to new section"); ?></a></b>  
    119 119                     </td>  
    120 120                     <td style="padding-left: 50px;">  
    121                          <b><a href="/<?php echo $ADMIN; ?>/articles/?Pub=<?php  p($srcSectionObj->getPublicationId()); ?>&Issue=<?php  p($srcSectionObj->getIssueId()); ?>&Section=<?php  p($srcSectionObj->getSectionId()); ?>&Language=<?php p($srcSectionObj->getLanguageId()); ?>"><?php putGS("Go to source section"); ?></a></b>  
      121                        <b><a href="/<?php echo $ADMIN; ?>/articles/?Pub=<?php  p($srcSectionObj->getPublicationId()); ?>&Issue=<?php  p($srcSectionObj->getIssueNumber()); ?>&Section=<?php  p($srcSectionObj->getSectionNumber()); ?>&Language=<?php p($srcSectionObj->getLanguageId()); ?>"><?php putGS("Go to source section"); ?></a></b>  
    121 121                     </td>  
    122 122                 </tr>  
  • trunk/campsite/implementation/management/priv/sections/edit.php

    r4054 r4085  
    31 31 camp_html_content_top(getGS("Configure section"), $topArray);  
    32 32  
    33   if ($User->hasPermission('ManageSection')) { ?>  
      33 $url_args1 = "Pub=$Pub&Issue=$Issue&Language=$Language";  
      34 $url_args2 = $url_args1."&Section=$Section";  
      35  
      36 ?>  
      37 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1" class="action_buttons" style="padding-top: 5px;">  
      38 <TR>  
      39     <TD><A HREF="/<?php echo $ADMIN; ?>/articles/?f_publication_id=<?php p($Pub); ?>&f_issue_number=<?php  p($sectionObj->getIssueNumber()); ?>&f_section_number=<?php p($sectionObj->getSectionNumber()); ?>&f_language_id=<?php  p($sectionObj->getLanguageId()); ?>"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/go_to.png" BORDER="0"></A></TD>  
      40     <TD><A HREF="/<?php echo $ADMIN; ?>/articles/?f_publication_id=<?php p($Pub); ?>&f_issue_number=<?php  p($sectionObj->getIssueNumber()); ?>&f_section_number=<?php p($sectionObj->getSectionNumber()); ?>&f_language_id=<?php  p($sectionObj->getLanguageId()); ?>"><B><?php  putGS("Go To Articles"); ?></B></A></TD>  
      41 </TR>  
      42 </TABLE>  
      43  
    34 44 <P>  
    35 45 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1" class="action_buttons">  
    36 46 <TR>  
    37       <TD><A HREF="add.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Language=<?php  p($Language); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD>  
    38       <TD><A HREF="add.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Language=<?php  p($Language); ?>" ><B><?php  putGS("Add new section"); ?></B></A></TD>  
      47     <TD><A HREF="add.php?<?php p($url_args1); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD>  
      48     <TD><A HREF="add.php?<?php p($url_args1); ?>" ><B><?php  putGS("Add new section"); ?></B></A></TD>  
      49  
      50     <TD style="padding-left: 20px;"><A HREF="duplicate.php?<?php p($url_args2); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/duplicate.png" BORDER="0"></A></TD>  
      51     <TD><A HREF="duplicate.php?<?php p($url_args2); ?>" ><B><?php  putGS("Duplicate"); ?></B></A></TD>  
      52      
      53     <TD style="padding-left: 20px;"><A HREF="del.php?<?php p($url_args2); ?>"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0"></A></TD>  
      54     <TD><A HREF="del.php?<?php p($url_args2); ?>" ><B><?php  putGS("Delete"); ?></B></A></TD>  
    39 55 </TR>  
    40 56 </TABLE>  
    41   <?php  } ?>  
    42 57  
    43 58 <P>  
     
    65 80         <?php  
    66 81         foreach ($templates as $template) {  
    67               pcomboVar($template->getTemplateId(),$sectionObj->getSectionTemplateId(),$template->getName());  
      82             camp_html_select_option($template->getTemplateId(), $sectionObj->getSectionTemplateId(), $template->getName());  
    67 82         }  
    68 83         ?>  
    79 94         <?php  
    80 95         foreach ($templates as $template) {  
    81               pcomboVar($template->getTemplateId(),$sectionObj->getArticleTemplateId(),$template->getName());  
      96             camp_html_select_option($template->getTemplateId(), $sectionObj->getArticleTemplateId(), $template->getName());  
    81 96         }  
    82 97         ?>  
  • trunk/campsite/implementation/management/priv/sections/do_del.php

    r4054 r4085  
    45 45     $logtext = getGS('Section $1 deleted from issue $2. $3 $4 of $5',  
    46 46         $sectionObj->getName(),  
    47           $issueObj->getIssueId(),  
      47         $issueObj->getIssueNumber(),  
    47 47         $issueObj->getName(),  
    48 48         $issueObj->getLanguageName(),  
  • trunk/campsite/implementation/management/priv/sections/do_edit.php

    r4077 r4085  
    69 69 }  
    70 70  
      71 $editUrl = "/$ADMIN/sections/edit.php?Pub=$Pub&Issue=$Issue&Language=$Language&Section=$Section";  
    71 72 if ($correct) {  
    72 73     $sectionObj->setName($cName);  
    73       $sectionObj->setShortName($cShortName);  
      74     $sectionObj->setUrlName($cShortName);  
    73 74     $sectionObj->setSectionTemplateId($cSectionTplId);  
    74 75     $sectionObj->setArticleTemplateId($cArticleTplId);  
     
    88 89         }  
    89 90     }  
    90       $logtext = getGS('Section $1 updated to issue $2. $3 ($4) of $5', $cName, $Issue,  
    91               $issueObj->getName(), $issueObj->getLanguageName(), $publicationObj->getName());  
      91     $logtext = getGS('Section #$1 "$2" updated. (Publication: $3, Issue: $4)',  
      92                      $Issue, $cName, $publicationObj->getPublicationId(), $issueObj->getIssueNumber());  
    92 93     Log::Message($logtext, $User->getUserName(), 21);  
    93        
      94     header("Location: $editUrl");  
      95     exit;  
    94 96 }  
    95 97 else {  
     
    97 99 }  
    98 100  
    99    
    100   camp_html_content_top("Updating section name");  
      101 $topArray = array("Pub" => $publicationObj, "Issue" => $issueObj, "Section" => $sectionObj);  
      102 camp_html_content_top("Updating section name", $topArray);  
    101 103 ?>  
    102 104  
    103 105 <P>  
    104   <CENTER>  
    105   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="8" class="message_box" ALIGN="CENTER">  
      106 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="8" class="message_box">  
    106 107 <TR>  
    107 108     <TD COLSPAN="2">  
     
    117 118         echo "<LI>".$error."</LI>";  
    118 119     }  
    119       if ($correct) {  
    120           if ($cSubs == "a") {  
    121               if ($add_subs_res > 0) { ?>  
    122                   <LI><?php  putGS('A total of $1 subscriptions were updated.','<B>'.$numSubscriptionsAdded.'</B>'); ?></LI>  
    123                   <?php  
    124               }  
    125           }  
    126           if ($cSubs == "d") {  
    127               if ($del_subs_res > 0) { ?>  
    128                   <LI><?php  putGS('A total of $1 subscriptions were updated.','<B>'.$numSubscriptionsDeleted.'</B>'); ?></LI>  
    129                   <?php  
    130               }  
    131           }  
    132       }  
    133    
    134       if ($modified) { ?>  
    135           <LI><?php  putGS('The section $1 has been successfuly modified.', '<B>'.htmlspecialchars($cName).'</B>'); ?></LI>  
    136           <?php   
    137       }  
    138       ?>       
      120     ?>  
    139 121     </BLOCKQUOTE>  
    140 122     </TD>  
    143 125     <TD COLSPAN="2">  
    144 126     <DIV ALIGN="CENTER">  
    145       <?php  
    146       if ($correct && $modified) { ?>  
    147           <INPUT TYPE="button" class="button" NAME="Done" VALUE="<?php  putGS('Done'); ?>" ONCLICK="location.href='/admin/sections/?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Language=<?php  p($Language); ?>'">  
    148           <?php   
    149       } else { ?>  
    150           <INPUT TYPE="button" class="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='/admin/sections/edit.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Language=<?php  p($Language); ?>&Section=<?php  p($Section); ?>'">  
    151           <?php   
    152       } ?>  
      127         <INPUT TYPE="button" class="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='<?php p($editUrl); ?>'">  
    153 128     </DIV>  
    154 129     </TD>  
    155 130 </TR>  
    156 131 </TABLE>  
    157   </CENTER>  
    158 132 <P>  
    159 133  
  • trunk/campsite/implementation/management/priv/sections/index.php

    r4054 r4085  
    66 66          
    67 67         <TD ALIGN="RIGHT">  
    68               <?php  p($section->getSectionId()); ?>  
      68             <?php  p($section->getSectionNumber()); ?>  
    68 68         </TD>  
    69 69          
    70 70         <TD >  
    71               <A HREF="/<?php p($ADMIN); ?>/articles/?Pub=<?php p($Pub); ?>&Issue=<?php  p($section->getIssueId()); ?>&Section=<?php p($section->getSectionId()); ?>&Language=<?php  p($section->getLanguageId()); ?>"><?php p(htmlspecialchars($section->getName())); ?></A>  
      71             <A HREF="/<?php p($ADMIN); ?>/articles/?f_publication_id=<?php p($Pub); ?>&f_issue_number=<?php  p($section->getIssueNumber()); ?>&f_section_number=<?php p($section->getSectionNumber()); ?>&f_language_id=<?php  p($section->getLanguageId()); ?>"><?php p(htmlspecialchars($section->getName())); ?></A>  
    71 71         </TD>  
    72 72          
     
    79 79         <?php  if ($User->hasPermission('ManageSection')) { ?>  
    80 80         <TD ALIGN="CENTER">  
    81               <A HREF="/<?php p($ADMIN); ?>/sections/edit.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($section->getIssueId()); ?>&Section=<?php p($section->getSectionId()); ?>&Language=<?php  p($section->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/configure.png" alt="<?php  putGS("Configure"); ?>" title="<?php  putGS("Configure"); ?>" border="0"></A>  
      81             <A HREF="/<?php p($ADMIN); ?>/sections/edit.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($section->getIssueNumber()); ?>&Section=<?php p($section->getSectionNumber()); ?>&Language=<?php  p($section->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/configure.png" alt="<?php  putGS("Configure"); ?>" title="<?php  putGS("Configure"); ?>" border="0"></A>  
    81 81         </TD>  
    82 82         <?php   } ?>  
     
    85 85         <?php if ($User->hasPermission('ManageSection') && $User->hasPermission('AddArticle')) { ?>  
    86 86         <TD ALIGN="CENTER">  
    87               <A HREF="/<?php p($ADMIN);?>/sections/duplicate.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php p($section->getSectionId()); ?>&Language=<?php  p($Language); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/duplicate.png" alt="<?php putGS('Duplicate'); ?>" title="<?php putGS('Duplicate'); ?>" border="0"></A>  
      87             <A HREF="/<?php p($ADMIN);?>/sections/duplicate.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php p($section->getSectionNumber()); ?>&Language=<?php  p($Language); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/duplicate.png" alt="<?php putGS('Duplicate'); ?>" title="<?php putGS('Duplicate'); ?>" border="0"></A>  
    87 87         </TD>  
    88 88         <?php } ?>  
    91 91         <?php if ($User->hasPermission('DeleteSection')) { ?>  
    92 92         <TD ALIGN="CENTER">  
    93               <A HREF="/<?php p($ADMIN); ?>/sections/del.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($section->getIssueId()); ?>&Section=<?php p($section->getSectionId()); ?>&Language=<?php  p($section->getLanguageId()); ?>&SectOffs=<?php p($SectOffs); ?>"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0" ALT="<?php putGS('Delete section $1', htmlspecialchars($section->getName())); ?>" TITLE="<?php  putGS('Delete section $1', htmlspecialchars($section->getName())); ?>"></A>  
      93             <A HREF="/<?php p($ADMIN); ?>/sections/del.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($section->getIssueNumber()); ?>&Section=<?php p($section->getSectionNumber()); ?>&Language=<?php  p($section->getLanguageId()); ?>&SectOffs=<?php p($SectOffs); ?>"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0" ALT="<?php putGS('Delete section $1', htmlspecialchars($section->getName())); ?>" TITLE="<?php  putGS('Delete section $1', htmlspecialchars($section->getName())); ?>"></A>  
    93 93         </TD>  
    94 94         <?php  } ?>  
  • trunk/campsite/implementation/management/priv/sections/add.php

    r4032 r4085  
    35 35 ?>  
    36 36 <P>  
    37   <CENTER>  
    38   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" CLASS="table_input" ALIGN="CENTER">  
      37 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" CLASS="table_input">  
    39 38 <FORM NAME="dialog" METHOD="POST" ACTION="do_add.php" >  
    40 39 <TR>  
    80 79     </TD>  
    81 80 </TR>  
    82   </TABLE></CENTER>  
      81 </TABLE>  
    82 81 </FORM>  
    83 82 <P>  
  • trunk/campsite/implementation/management/priv/camp_html.php

    r4084 r4085  
    11 11  
    12 12 /**  
      13  * Create an HTML OPTION element.  
      14  *  
      15  * @param string $p_value  
      16  * @param string $p_selectedValue  
      17  * @param string $p_printValue  
      18  * @return void  
      19  */  
      20 function camp_html_select_option($p_value, $p_selectedValue, $p_printValue)  
      21 {  
      22     print '<OPTION VALUE="'.htmlspecialchars($p_value, ENT_QUOTES).'"';  
      23     if (!strcmp($p_value, $p_selectedValue)) {  
      24         print ' SELECTED';  
      25     }  
      26     print '>'.htmlspecialchars($p_printValue);  
      27 } // fn camp_html_select_option  
      28  
      29  
      30 /**  
    13 31  * Display the copyright notice and close the HTML page.  
    14 32  */  
     
    109 127     global $ADMIN;  
    110 128     $str = "/$ADMIN/articles/".$p_targetFileName  
    111           ."?Pub=".$p_articleObj->getPublicationId()  
    112           ."&Issue=".$p_articleObj->getIssueId()  
    113           ."&Section=".$p_articleObj->getSectionId()  
    114           ."&Article=".$p_articleObj->getArticleId()  
    115           ."&Language=".$p_interfaceLanguageId  
    116           ."&sLanguage=".$p_articleObj->getLanguageId();  
      129         ."?f_publication_id=".$p_articleObj->getPublicationId()  
      130         ."&f_issue_number=".$p_articleObj->getIssueNumber()  
      131         ."&f_section_number=".$p_articleObj->getSectionNumber()  
      132         ."&f_article_number=".$p_articleObj->getArticleNumber()  
      133         ."&f_language_id=".$p_interfaceLanguageId  
      134         ."&f_language_selected=".$p_articleObj->getLanguageId();  
    117 135     if ($p_backLink != "") {  
    118 136         $str .="&Back=".urlencode($p_backLink);  
     
    200 218                "/$ADMIN/issues/"  
    201 219                ."?Pub=".$issueObj->getPublicationId()  
    202                  ."&Issue=".$issueObj->getIssueId()  
      220                ."&Issue=".$issueObj->getIssueNumber()  
    202 220                ."&Language=".$issueObj->getLanguageId(),  
    203 221                false);  
     
    207 225                "/$ADMIN/issues/edit.php"  
    208 226                ."?Pub=".$issueObj->getPublicationId()  
    209                  ."&Issue=".$issueObj->getIssueId()  
      227                ."&Issue=".$issueObj->getIssueNumber()  
    209 227                ."&Language=".$issueObj->getLanguageId());  
    210 228     }  
     
    215 233                 "/$ADMIN/sections/"  
    216 234                 ."?Pub=".$sectionObj->getPublicationId()  
    217                   ."&Issue=".$sectionObj->getIssueId()  
      235                 ."&Issue=".$sectionObj->getIssueNumber()  
    217 235                 ."&Language=".$sectionObj->getLanguageId()  
    218                   ."&Section=".$sectionObj->getSectionId(),  
      236                 ."&Section=".$sectionObj->getSectionNumber(),  
    218 236                 false);  
    219 237         $name = htmlspecialchars($sectionObj->getName());  
     
    223 241                 "/$ADMIN/sections/edit.php"  
    224 242                 ."?Pub=".$sectionObj->getPublicationId()  
    225                   ."&Issue=".$sectionObj->getIssueId()  
      243                 ."&Issue=".$sectionObj->getIssueNumber()  
    225 243                 ."&Language=".$sectionObj->getLanguageId()  
    226                   ."&Section=".$sectionObj->getSectionId());  
      244                 ."&Section=".$sectionObj->getSectionNumber());  
    226 244     }  
    227 245     if (!is_null($articleObj)) {  
    231 249         $breadcrumbs[] = array($prompt,  
    232 250                 "/$ADMIN/articles/index.php"  
    233                   ."?Pub=" . $articleObj->getPublicationId()  
    234                   ."&Issue=".$articleObj->getIssueId()  
    235                   ."&Language=".$sectionObj->getLanguageId()  
    236                   ."&Section=".$articleObj->getSectionId()  
    237                   ."&Article=".$articleObj->getArticleId(),                 
      251                 ."?f_publication_id=" . $articleObj->getPublicationId()  
      252                 ."&f_issue_number=".$articleObj->getIssueNumber()  
      253                 ."&f_language_id=".$sectionObj->getLanguageId()  
      254                 ."&f_section_number=".$articleObj->getSectionNumber()  
      255                 ."&f_article_number=".$articleObj->getArticleNumber(),                 
    238 256                 false);  
    239 257         $name = htmlspecialchars($articleObj->getName())." (".htmlspecialchars($articleObj->getLanguageName()).")";  
    240 258         $breadcrumbs[] = array($name,  
    241 259                 "/$ADMIN/articles/edit.php"  
    242                   ."?Pub=" . $articleObj->getPublicationId()  
    243                   ."&Issue=".$articleObj->getIssueId()  
    244                   ."&Language=".$sectionObj->getLanguageId()  
    245                   ."&Section=".$articleObj->getSectionId()  
    246                   ."&Article=".$articleObj->getArticleId()  
    247                   ."&sLanguage=".$articleObj->getLanguageId());  
      260                 ."?f_publication_id=" . $articleObj->getPublicationId()  
      261                 ."&f_issue_number=".$articleObj->getIssueNumber()  
      262                 ."&f_language_id=".$sectionObj->getLanguageId()  
      263                 ."&f_section_number=".$articleObj->getSectionNumber()  
      264                 ."&f_article_number=".$articleObj->getArticleNumber()  
      265                 ."&f_language_selected=".$articleObj->getLanguageId());  
    248 266     }  
    249 267     if (is_array($p_extraBreadcrumbs)) {  
  • trunk/campsite/implementation/management/priv/menu.php

    r4078 r4085  
    59 59             array('ORDER BY'=>array('Number'=>'DESC'), 'LIMIT' => '5'));  
    60 60     foreach ($issues[$publication->getPublicationId()] as $issue) {  
    61           $sections[$issue->getPublicationId()][$issue->getIssueId()][$issue->getLanguageId()] =  
      61         $sections[$issue->getPublicationId()][$issue->getIssueNumber()][$issue->getLanguageId()] =  
    61 61             Section::GetSections($issue->getPublicationId(),  
    62                   $issue->getIssueId(), $issue->getLanguageId());  
      62                 $issue->getIssueNumber(), $issue->getLanguageId());  
    62 62     }  
    63 63 }  
     
    74 74     if (isset($issues[$pubId])) {  
    75 75         foreach ($issues[$pubId] as $issue) {  
    76               $issueId = $issue->getIssueId();  
      76             $issueId = $issue->getIssueNumber();  
    76 76             $languageId = $issue->getLanguageId();  
    77 77             $menu_item_issue =& DynMenuItem::Create(htmlspecialchars($issue->getName()),  
    82 82             if (isset($sections[$pubId][$issueId][$languageId])) {  
    83 83                 foreach ($sections[$pubId][$issueId][$languageId] as $section) {  
    84                       $sectionId = $section->getSectionId();  
      84                     $sectionId = $section->getSectionNumber();  
    84 84                     $menu_item_section =& DynMenuItem::Create(  
    85 85                         htmlspecialchars($section->getName()),  
    86                           "/$ADMIN/articles/index.php".  
    87                           "?Pub=$pubId&Issue=$issueId&Language=$languageId&Section=$sectionId",  
      86                         "/$ADMIN/articles/index.php"  
      87                         ."?f_publication_id=$pubId"  
      88                         ."&f_issue_number=$issueId"  
      89                         ."&f_language_id=$languageId"  
      90                         ."&f_section_number=$sectionId",  
    88 91                         array("icon" => $icon_bullet));  
    89 92                     $menu_item_issue->addItem($menu_item_section);  
  • trunk/campsite/implementation/management/priv/login.php

    r4032 r4085  
    58 58  
    59 59 // Load the language files.  
    60   selectLanguageFile("globals");  
    61   selectLanguageFile("home");  
      60 camp_load_language("globals");  
      61 camp_load_language("home");  
    62 62  
    63 63 ?>  
  • trunk/campsite/implementation/management/priv/users/info.php

    r4077 r4085  
    129 129                 $Type = Input::Get('Type', 'string', '');  
    130 130                 foreach ($userTypes as $tmpUserType) {  
    131                       pcomboVar($tmpUserType['Name'], $Type, $tmpUserType['Name']);  
      131                     camp_html_select_option($tmpUserType['Name'], $Type, $tmpUserType['Name']);  
    131 131                 }  
    132 132                 ?>  
  • trunk/campsite/implementation/management/priv/users/subscriptions/sections/do_add.php

    r4077 r4085  
    25 25 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
    26 26 $f_subscription_id = Input::Get('f_subscription_id', 'int', 0);  
    27   $f_section_id = Input::Get('f_section_id', 'int', 0);  
      27 $f_section_number = Input::Get('f_section_number', 'int', 0);  
    27 27 $f_subscription_start_date = Input::Get('f_subscription_start_date');  
    28 28 $f_subscription_days = Input::Get('f_subscription_days');  
    35 35 $errorMsgs = array();  
    36 36  
    37   if ($f_section_id != 0) {  
    38       $subscriptionSection =& new SubscriptionSection($f_subscription_id, $f_section_id);  
      37 if ($f_section_number != 0) {  
      38     $subscriptionSection =& new SubscriptionSection($f_subscription_id, $f_section_number);  
    39 39     $columns = array('StartDate' => $f_subscription_start_date,  
    40 40                      'Days' => $f_subscription_days,  
  • trunk/campsite/implementation/management/priv/users/subscriptions/sections/change.php

    r4077 r4085  
    24 24 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
    25 25 $f_subscription_id = Input::Get('f_subscription_id', 'int', 0);  
    26   $f_section_id = Input::Get('f_section_id', 'int', null);  
      26 $f_section_number = Input::Get('f_section_number', 'int', null);  
    26 26  
    27 27 $publicationObj =& new Publication($f_publication_id);  
     
    35 35 }  
    36 36  
    37   //$subscriptionSection =& new SubscriptionSection($f_subscription_id, $f_section_id);  
    38   $subscriptionSections = SubscriptionSection::GetSubscriptionSections($f_subscription_id, $f_section_id);  
      37 //$subscriptionSection =& new SubscriptionSection($f_subscription_id, $f_section_number);  
      38 $subscriptionSections = SubscriptionSection::GetSubscriptionSections($f_subscription_id, $f_section_number);  
    39 39 $subscriptionSection = array_pop($subscriptionSections);  
    40 40  
     
    69 69     <TD>  
    70 70     <?php  
    71       if ($f_section_id > 0) {  
      71     if ($f_section_number > 0) {  
    71 71         p(htmlspecialchars($subscriptionSection->getProperty('Name')));  
    72 72     } else {  
    102 102     <INPUT TYPE="HIDDEN" NAME="f_user_id" VALUE="<?php p($f_user_id); ?>">  
    103 103     <INPUT TYPE="HIDDEN" NAME="f_subscription_id" VALUE="<?php p($f_subscription_id); ?>">  
    104       <INPUT TYPE="HIDDEN" NAME="f_section_id" VALUE="<?php p($f_section_id); ?>">  
      104     <INPUT TYPE="HIDDEN" NAME="f_section_number" VALUE="<?php p($f_section_number); ?>">  
    104 104     <INPUT TYPE="HIDDEN" NAME="f_publication_id" VALUE="<?php p($f_publication_id); ?>">  
    105 105     <INPUT TYPE="submit" class="button" NAME="Save" VALUE="<?php  putGS('Save'); ?>">  
  • trunk/campsite/implementation/management/priv/users/subscriptions/sections/do_del.php

    r4077 r4085  
    24 24 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
    25 25 $f_subscription_id = Input::Get('f_subscription_id', 'int', 0);  
    26   $f_section_id = Input::Get('f_section_id', 'int', 0);  
      26 $f_section_number = Input::Get('f_section_number', 'int', 0);  
    26 26  
    27 27 $publicationObj =& new Publication($f_publication_id);  
    30 30 $manageUser =& new User($f_user_id);  
    31 31  
    32   $subscriptionSection =& new SubscriptionSection($f_subscription_id, $f_section_id);  
      32 $subscriptionSection =& new SubscriptionSection($f_subscription_id, $f_section_number);  
    32 32 $subscriptionSection->delete();  
    33 33 header("Location: /$ADMIN/users/subscriptions/sections/?f_user_id=$f_user_id&f_subscription_id=$f_subscription_id&f_publication_id=$f_publication_id");  
  • trunk/campsite/implementation/management/priv/users/subscriptions/sections/do_change.php

    r4077 r4085  
    24 24 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
    25 25 $f_subscription_id = Input::Get('f_subscription_id', 'int', 0);  
    26   $f_section_id = Input::Get('f_section_id', 'int', null);  
      26 $f_section_number = Input::Get('f_section_number', 'int', null);  
    26 26 $f_subscription_start_date = Input::Get('f_subscription_start_date');  
    27 27 $f_subscription_days = Input::Get('f_subscription_days', 'int', 0);  
     
    38 38 }  
    39 39  
    40   //$subscriptionSection =& new SubscriptionSection($f_subscription_id, $f_section_id);  
    41   $subscriptionSections = SubscriptionSection::GetSubscriptionSections($f_subscription_id, $f_section_id);  
      40 //$subscriptionSection =& new SubscriptionSection($f_subscription_id, $f_section_number);  
      41 $subscriptionSections = SubscriptionSection::GetSubscriptionSections($f_subscription_id, $f_section_number);  
    42 42 //print_r($subscriptionSections);  
    43 43 //exit;  
    81 81     <TD COLSPAN="2">  
    82 82     <DIV ALIGN="CENTER">  
    83       <INPUT TYPE="button" class="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='/<?php p($ADMIN); ?>/users/subscriptions/sections/change.php?f_publication_id=<?php p($f_publication_id); ?>&f_user_id=<?php  p($f_user_id); ?>&f_subscription_id=<?php p($f_subscription_id); ?>&f_section_id=<?php p($f_section_id); ?>'">  
      83     <INPUT TYPE="button" class="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='/<?php p($ADMIN); ?>/users/subscriptions/sections/change.php?f_publication_id=<?php p($f_publication_id); ?>&f_user_id=<?php  p($f_user_id); ?>&f_subscription_id=<?php p($f_subscription_id); ?>&f_section_number=<?php p($f_section_number); ?>'">  
    83 83     </DIV>  
    84 84     </TD>  
  • trunk/campsite/implementation/management/priv/users/subscriptions/sections/index.php

    r4077 r4085  
    83 83 <TR <?php  if ($color) { $color=0; ?>class="list_row_even"<?php  } else { $color=1; ?>class="list_row_odd"<?php  } ?>>  
    84 84     <TD >  
    85           <A HREF="/<?php p($ADMIN); ?>/users/subscriptions/sections/change.php?f_user_id=<?php p($f_user_id); ?>&f_publication_id=<?php p($f_publication_id); ?>&f_subscription_id=<?php p($f_subscription_id); ?>&f_section_id=<?php p($section->getSectionNumber()); ?>"><?php p(htmlspecialchars($section->getProperty('Name'))); ?></A>  
      85         <A HREF="/<?php p($ADMIN); ?>/users/subscriptions/sections/change.php?f_user_id=<?php p($f_user_id); ?>&f_publication_id=<?php p($f_publication_id); ?>&f_subscription_id=<?php p($f_subscription_id); ?>&f_section_number=<?php p($section->getSectionNumber()); ?>"><?php p(htmlspecialchars($section->getProperty('Name'))); ?></A>  
    85 85     </TD>  
    86 86      
    101 101      
    102 102     <TD ALIGN="CENTER">  
    103           <A HREF="/<?php p($ADMIN); ?>/users/subscriptions/sections/do_del.php?f_user_id=<?php p($f_user_id); ?>&f_publication_id=<?php p($f_publication_id); ?>&f_subscription_id=<?php p($f_subscription_id); ?>&f_section_id=<?php p($section->getSectionNumber()); ?>"><IMG SRC="<?php echo $Campsite['ADMIN_IMAGE_BASE_URL']; ?>/delete.png" BORDER="0" ALT="<?php  putGS('Delete subscription to section $1?', htmlspecialchars($section->getProperty('Name'))); ?>" TITLE="<?php  putGS('Delete subscription to section $1?', htmlspecialchars($section->getProperty('Name'))); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the subscription to the section $1?', htmlspecialchars($section->getProperty('Name'))); ?>');"></A>  
      103         <A HREF="/<?php p($ADMIN); ?>/users/subscriptions/sections/do_del.php?f_user_id=<?php p($f_user_id); ?>&f_publication_id=<?php p($f_publication_id); ?>&f_subscription_id=<?php p($f_subscription_id); ?>&f_section_number=<?php p($section->getSectionNumber()); ?>"><IMG SRC="<?php echo $Campsite['ADMIN_IMAGE_BASE_URL']; ?>/delete.png" BORDER="0" ALT="<?php  putGS('Delete subscription to section $1?', htmlspecialchars($section->getProperty('Name'))); ?>" TITLE="<?php  putGS('Delete subscription to section $1?', htmlspecialchars($section->getProperty('Name'))); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the subscription to the section $1?', htmlspecialchars($section->getProperty('Name'))); ?>');"></A>  
    103 103     </TD>  
    104 104 </TR>  
  • trunk/campsite/implementation/management/priv/users/subscriptions/sections/add.php

    r4077 r4085  
    24 24 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
    25 25 $f_subscription_id = Input::Get('f_subscription_id', 'int', 0);  
    26   $f_section_id = Input::Get('f_section_id', 'int', 0);  
      26 $f_section_number = Input::Get('f_section_number', 'int', 0);  
    26 26  
    27 27 $publicationObj =& new Publication($f_publication_id);  
    62 62     <TD ALIGN="RIGHT" ><?php  putGS("Section"); ?>:</TD>  
    63 63     <TD>  
    64           <SELECT NAME="f_section_id" class="input_select">  
      64         <SELECT NAME="f_section_number" class="input_select">  
    64 64         <OPTION VALUE="0">All sections</OPTION>  
    65 65         <?php   
    66 66         foreach ($sections as $section) {  
    67               pComboVar($section['id'], '', $section['name']." (".$section['id'].")");  
      67             camp_html_select_option($section['id'], '', $section['name']." (".$section['id'].")");  
    67 67         }  
    68 68         ?>  
  • trunk/campsite/implementation/management/priv/users/subscriptions/add.php

    r4073 r4085  
    61 61         <?php  
    62 62         foreach ($publications as $publication) {  
    63               pComboVar($publication->getPublicationId(), '', $publication->getName());  
      63             camp_html_select_option($publication->getPublicationId(), '', $publication->getName());  
    63 63         }  
    64 64         ?>  
  • trunk/campsite/implementation/management/priv/users/index.php

    r4077 r4085  
    59 59         <select name="subscription_how" class="input_select" style="width: 100px;">  
    60 60         <?php  
    61           pcomboVar("expires", $subscription_how, getGS("expires"));  
    62           pcomboVar("starts", $subscription_how, getGS("starts"));  
      61         camp_html_select_option("expires", $subscription_how, getGS("expires"));  
      62         camp_html_select_option("starts", $subscription_how, getGS("starts"));  
    63 63         ?>  
    64 64         </select>  
    65 65         <select name="subscription_when" class="input_select" style="width: 100px;">  
    66 66         <?PHP  
    67           pcomboVar("before", $subscription_when, getGS("before"));  
    68           pcomboVar("after", $subscription_when, getGS("after"));  
    69           pcomboVar("on", $subscription_when, getGS("on"));  
      67         camp_html_select_option("before", $subscription_when, getGS("before"));  
      68         camp_html_select_option("after", $subscription_when, getGS("after"));  
      69         camp_html_select_option("on", $subscription_when, getGS("on"));  
    70 70         ?>  
    71 71         </select>  
    76 76         <option value=""></option>  
    77 77         <?PHP  
    78           pcomboVar("active", $subscription_status, getGS("active"));  
    79           pcomboVar("inactive", $subscription_status, getGS("inactive"));  
      78         camp_html_select_option("active", $subscription_status, getGS("active"));  
      79         camp_html_select_option("inactive", $subscription_status, getGS("inactive"));  
    80 80         ?>  
    81 81         </select>  
  • trunk/campsite/implementation/management/priv/country/index.php

    r4067 r4085  
    51 51                 <?php  
    52 52                 foreach ($languages as $language) {  
    53                       pcomboVar($language->getLanguageId(), $f_language_selected, $language->getNativeName());  
      53                     camp_html_select_option($language->getLanguageId(), $f_language_selected, $language->getNativeName());  
    53 53                 }  
    54 54                 ?>  
  • trunk/campsite/implementation/management/priv/country/add.php

    r4067 r4085  
    50 50         <?php   
    51 51         foreach ($languages as $language) {  
    52               pcomboVar($language->getLanguageId(), 0, $language->getNativeName());  
      52             camp_html_select_option($language->getLanguageId(), 0, $language->getNativeName());  
    52 52         } ?>  
    53 53         </SELECT>  
  • trunk/campsite/implementation/management/priv/logs/index.php

    r4077 r4085  
    55 55                 <?php  
    56 56                 foreach ($events as $event) {  
    57                       pcomboVar($event->getEventId(), $f_event_search_id, htmlspecialchars($event->getName()));  
      57                     camp_html_select_option($event->getEventId(), $f_event_search_id, htmlspecialchars($event->getName()));  
    57 57                 }  
    58 58                 ?>  
    87 87          
    88 88         <TD>  
    89               <?php  p(htmlspecialchars($entry->getUserName())); ?>   
      89             <?php  p(htmlspecialchars($entry->getProperty("full_name"))); ?>   
    89 89         </TD>  
    90 90      
  • trunk/campsite/implementation/management/priv/articles/autopublish_do_add.php

    r3903 r4085  
    13 13 }  
    14 14  
    15   $Pub = Input::Get('Pub', 'int', 0);  
    16   $Issue = Input::Get('Issue', 'int', 0);  
    17   $Section = Input::Get('Section', 'int', 0);  
    18   $Language = Input::Get('Language', 'int', 0);  
    19   $sLanguage = Input::Get('sLanguage', 'int', 0);  
    20   $Article = Input::Get('Article', 'int', 0);  
    21   $publishDate = trim(Input::Get('publish_date'));  
    22   $publishHour = trim(Input::Get('publish_hour', 'int', 0));  
    23   $publishMinute = trim(Input::Get('publish_min', 'int', 0));  
    24   $publishAction = Input::Get('publish_action', 'string', '', true);  
    25   $frontPageAction = Input::Get('front_page_action', 'string', '', true);  
    26   $sectionPageAction = Input::Get('section_page_action', 'string', '', true);  
    27   $BackLink = Input::Get('Back', 'string', "/$ADMIN/articles/index.php"  
    28                          ."?Pub=$Pub&Issue=$Issue&Section=$Section&sLanguage=$sLanguage&Language=$Language",  
    29                          true);  
      15 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
      16 $f_issue_number = Input::Get('f_issue_number', 'int', 0);  
      17 $f_section_number = Input::Get('f_section_number', 'int', 0);  
      18 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      19 $f_language_selected = Input::Get('f_language_selected', 'int', 0);  
      20 $f_publish_date = trim(Input::Get('f_publish_date'));  
      21 $f_publish_hour = trim(Input::Get('f_publish_hour', 'int', 0));  
      22 $f_publish_minute = trim(Input::Get('f_publish_minute', 'int', 0));  
      23 $f_publish_action = Input::Get('f_publish_action', 'string', '', true);  
      24 $f_front_page_action = Input::Get('f_front_page_action', 'string', '', true);  
      25 $f_section_page_action = Input::Get('f_section_page_action', 'string', '', true);  
      26 $f_article_code = Input::Get('f_article_code', 'array', 0);  
      27  
      28 // Get all the articles.  
      29 $articles = array();  
      30 $errorArticles = array();  
      31 foreach ($f_article_code as $code) {  
      32     list($articleId, $languageId) = split("_", $code);  
      33     $tmpArticle =& new Article($languageId, $articleId);  
      34     if ($tmpArticle->getPublished() != 'N') {  
      35         $articles[] = $tmpArticle;  
      36     }  
      37     else {  
      38         $errorArticles[] = $tmpArticle;  
      39     }  
      40 }  
      41  
      42 //$BackLink = Input::Get('Back', 'string', "/$ADMIN/articles/index.php"  
      43 //                       ."?f_publication_id=$f_publication_id&f_issue_number=$f_issue_number&Section=$f_section_number&f_language_selected=$f_language_selected&Language=$f_language_id",  
      44 //                       true);  
    30 45                          
    31 46 if (!Input::IsValid()) {  
     
    34 49 }  
    35 50  
    36   $publicationObj =& new Publication($Pub);  
      51 $publicationObj =& new Publication($f_publication_id);  
    36 51 if (!$publicationObj->exists()) {  
    37       camp_html_display_error(getGS('Publication does not exist.'), $BackLink);  
      52     camp_html_display_error(getGS('Publication does not exist.'));  
    37 52     exit;     
    38 53 }  
    39 54  
    40   $issueObj =& new Issue($Pub, $Language, $Issue);  
      55 $issueObj =& new Issue($f_publication_id, $f_language_id, $f_issue_number);  
    40 55 if (!$issueObj->exists()) {  
    41       camp_html_display_error(getGS('Issue does not exist.'), $BackLink);  
      56     camp_html_display_error(getGS('Issue does not exist.'));  
    41 56     exit;     
    42 57 }  
    43 58  
    44   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
      59 $sectionObj =& new Section($f_publication_id, $f_issue_number, $f_language_id, $f_section_number);  
    44 59 if (!$sectionObj->exists()) {  
    45       camp_html_display_error(getGS('Section does not exist.'), $BackLink);  
      60     camp_html_display_error(getGS('Section does not exist.'));  
    45 60     exit;     
    46 61 }  
    47 62  
    48   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
    49   if (!$articleObj->exists()) {  
    50       camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
    51       exit;  
    52   }  
    53    
    54   $languageObj =& new Language($Language);  
    55   $sLanguageObj =& new Language($sLanguage);  
    56 63  
    57 64 $correct = true;  
    58 65 $created = false;  
    59   if ( ( ($publishDate == "") || ($publishHour == "") || ($publishMinute == "") )  
    60       || ( ($publishAction != "P") && ($publishAction != "U")  
    61       && ($frontPageAction != "S") && ($frontPageAction != "R")  
    62       && ($sectionPageAction != "S") && ($sectionPageAction != "R") ) ) {  
      66 $errorMsgs = array();  
      67 if ($f_publish_date == "") {  
      68     $errorMsgs[] = getGS('You must complete the $1 field.','<B>'.getGS('Date').'</B>' );  
    63 69     $correct = false;  
    64 70 }  
    65   else {  
    66       $publishTime = $publishDate . " " . $publishHour . ":" . $publishMinute . ":00";  
    67       $articlePublishObj =& new ArticlePublish($Article, $sLanguage, $publishTime);  
    68       if (!$articlePublishObj->exists()) {  
      71  
      72 if ($f_publish_hour == "" || $f_publish_minute == "") {  
      73     $errorMsgs[] = getGS('You must complete the $1 field.','<B>'.getGS('Time').'</B>' );  
      74     $correct = false;  
      75 }  
      76  
      77 if ( ($f_publish_action != "P") && ($f_publish_action != "U")  
      78      && ($f_front_page_action != "S") && ($f_front_page_action != "R")  
      79      && ($f_section_page_action != "S") && ($f_section_page_action != "R") ) {  
      80     $errorMsgs[] = getGS('You must select an action.');  
      81     $correct = false;  
      82 }  
      83  
      84 if ( (count($articles) == 0) && (count($errorArticles) > 0) ) {  
      85     $errorMsgs[] = getGS("The article is new; it is not possible to schedule it for automatic publishing.");  
      86     $correct = false;  
      87 }  
      88  
      89 if ($correct) {  
      90     $publishTime = $f_publish_date . " " . $f_publish_hour . ":" . $f_publish_minute . ":00";  
      91     foreach ($articles as $tmpArticle) {  
      92         $articlePublishObj =& new ArticlePublish();  
    69 93         $articlePublishObj->create();  
      94         $articlePublishObj->setArticleId($tmpArticle->getArticleNumber());  
      95         $articlePublishObj->setLanguageId($tmpArticle->getLanguageId());  
      96         $articlePublishObj->setActionTime($publishTime);  
    70 97         $created = true;  
    71       }  
    72       if ($publishAction == "P" || $publishAction == "U") {  
    73           $articlePublishObj->setPublishAction($publishAction);  
    74       }  
    75       if ($frontPageAction == "S" || $frontPageAction == "R") {  
    76           $articlePublishObj->setFrontPageAction($frontPageAction);  
    77       }  
    78       if ($sectionPageAction == "S" || $sectionPageAction == "R") {  
    79           $articlePublishObj->setSectionPageAction($sectionPageAction);  
    80       }  
    81       $redirect = camp_html_article_url($articleObj, $Language, "autopublish.php", $BackLink);  
    82       header("Location: $redirect");  
      98         if ($f_publish_action == "P" || $f_publish_action == "U") {  
      99             $articlePublishObj->setPublishAction($f_publish_action);  
      100         }  
      101         if ($f_front_page_action == "S" || $f_front_page_action == "R") {  
      102             $articlePublishObj->setFrontPageAction($f_front_page_action);  
      103         }  
      104         if ($f_section_page_action == "S" || $f_section_page_action == "R") {  
      105             $articlePublishObj->setSectionPageAction($f_section_page_action);  
      106         }  
      107     }  
      108     $args = $_REQUEST;  
      109     unset($args["f_article_code"]);  
      110     $argsStr = camp_implode_keys_and_values($args, "=", "&");  
      111     $url = "Location: /$ADMIN/articles/index.php?".$argsStr;  
      112     //echo $url;  
      113     header($url);     
      114 //  $redirect = camp_html_article_url($articleObj, $f_language_id, "autopublish.php", $BackLink);  
      115 //  header("Location: $redirect");  
    83 116     exit;  
    84 117 }  
    85 118 $topArray = array('Pub' => $publicationObj, 'Issue' => $issueObj,  
    86                     'Section' => $sectionObj, 'Article'=>$articleObj);  
      119                   'Section' => $sectionObj);  
    86 119 camp_html_content_top(getGS("Scheduling a new publish action"), $topArray);  
    87   if ($articleObj->getPublished() != 'N') {  
    88 120 ?>  
    89    
    90 121 <P>  
    91   <CENTER>  
    92   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="8" class="message_box" ALIGN="CENTER">  
      122 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="8" class="message_box">  
    93 123 <TR>  
    94 124     <TD COLSPAN="2">  
    105 135 </TR>  
    106 136 <TR>  
    107       <TD COLSPAN="2"><BLOCKQUOTE>  
    108       <?php  
    109       if ($publishDate == "") { ?>     
    110           <LI><?php putGS('You must complete the $1 field.','<B>'.getGS('Date').'</B>' ); ?></LI>  
    111           <?php  
    112       }  
    113    
    114       if ($publishHour == "" || $publishMinute == "") { ?>     
    115           <LI><?php putGS('You must complete the $1 field.','<B>'.getGS('Time').'</B>' ); ?></LI>  
    116           <?php  
    117       }  
    118    
    119       if ( ($publishAction != "P") && ($publishAction != "U")  
    120           && ($frontPageAction != "S") && ($frontPageAction != "R")  
    121           && ($sectionPageAction != "S") && ($sectionPageAction != "R") ) {?>  
    122           <LI><?php putGS('You must select an action.'); ?></LI>  
    123       <?php  
    124       }  
    125       ?>   
    126       </BLOCKQUOTE>  
      137     <TD COLSPAN="2">  
      138         <BLOCKQUOTE>  
      139         <?php  
      140         foreach ($errorMsgs as $errorMsg) { ?>  
      141             <li><?php p($errorMsg); ?></li>  
      142             <?php  
      143         }  
      144         ?>  
      145         </BLOCKQUOTE>  
    127 146     </TD>  
    128 147     </TR>  
    129 148     <TR>  
    130 149         <TD COLSPAN="2" align="center">  
    131               <INPUT TYPE="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/autopublish.php?Pub=<?php p($Pub); ?>&Issue=<?php p($Issue); ?>&Section=<?php p($Section); ?>&Article=<?php p($Article); ?>&Language=<?php p($Language); ?>&sLanguage=<?php p($sLanguage); ?>'" class="button">  
      150             <INPUT TYPE="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/autopublish.php?f_publication_id=<?php p($f_publication_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_article_number=<?php p($f_article_number); ?>&f_language_id=<?php p($f_language_id); ?>&f_language_selected=<?php p($f_language_selected); ?>'" class="button">  
    131 150         </TD>  
    132 151     </TR>  
    133 152 </TABLE>  
    134   </CENTER>  
    135 153 <P>  
    136    
    137   <?php } else { ?><BLOCKQUOTE>  
    138       <CENTER><TABLE BORDER="0" CELLSPACING="0" CELLPADDING="8" class="message_box" ALIGN="CENTER">  
    139       <TR>  
    140           <TD COLSPAN="2">  
    141               <B> <?php  putGS("Scheduling a new publish action"); ?> </B>  
    142               <HR NOSHADE SIZE="1" COLOR="BLACK">  
    143           </TD>  
    144       </TR>  
    145       <TR>  
    146           <TD COLSPAN="2"><BLOCKQUOTE><?php putGS("The article is new; it is not possible to schedule it for automatic publishing."); ?></BLOCKQUOTE></TD>  
    147       </TR>  
    148       <TR>  
    149           <TD COLSPAN="2">  
    150           <DIV ALIGN="CENTER">  
    151       <INPUT TYPE="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/edit.php?Pub=<?php p($Pub); ?>&Issue=<?php p($Issue); ?>&Section=<?php p($Section); ?>&Article=<?php p($Article); ?>&Language=<?php p($Language); ?>&sLanguage=<?php p($sLanguage); ?>'">  
    152           </DIV>  
    153           </TD>  
    154       </TR>  
    155       </TABLE></CENTER>  
    156   </BLOCKQUOTE>  
    157   <?php }  
      154 <?php  
    158 155 camp_html_copyright_notice();  
    159   ?>  
    160   </BODY>  
    161    
    162   </HTML>  
      156 ?>  
  • trunk/campsite/implementation/management/priv/articles/do_duplicate.php

    r4083 r4085  
    11 11  
    12 12  
    13   $Pub = Input::Get('Pub', 'int', 0);  
    14   $Issue = Input::Get('Issue', 'int', 0);  
    15   $Section = Input::Get('Section', 'int', 0);  
    16   $Language = Input::Get('Language', 'int', 0);  
    17   $Article = Input::Get('Article', 'int', 0);  
      13 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
      14 $f_issue_number = Input::Get('f_issue_number', 'int', 0);  
      15 $f_section_number = Input::Get('f_section_number', 'int', 0);  
      16 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      17 $f_article_number = Input::Get('f_article_number', 'int', 0);  
    18 18 //$sLanguage = Input::Get('sLanguage', 'int', 0);  
    19   $sLanguage = $Language;  
      19 $sLanguage = $f_language_id;  
    19 19 $f_destination_publication_id = Input::Get('f_destination_publication_id', 'int', 0);  
    20 20 $f_destination_issue_id = Input::Get('f_destination_issue_id', 'int', 0);  
     
    34 34 }  
    35 35  
    36   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
    37   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    38   $issueObj =& new Issue($Pub, $Language, $Issue);  
    39   $publicationObj =& new Publication($Pub);  
      36 $articleObj =& new Article($sLanguage, $f_article_number);  
      37 $sectionObj =& new Section($f_publication_id, $f_issue_number, $f_language_id, $f_section_number);  
      38 $issueObj =& new Issue($f_publication_id, $f_language_id, $f_issue_number);  
      39 $publicationObj =& new Publication($f_publication_id);  
    40 40  
    41 41 $articleCopy = $articleObj->copy($f_destination_publication_id, $f_destination_issue_id, $f_destination_section_id, $User->getId());  
    43 43  
    44 44 $logtext = getGS('Article $1 added to $2. $3 from $4. $5 of $6',  
    45       $articleCopy->getName(), $sectionObj->getSectionId(),  
    46       $sectionObj->getName(), $issueObj->getIssueId(),  
      45     $articleCopy->getName(), $sectionObj->getSectionNumber(),  
      46     $sectionObj->getName(), $issueObj->getIssueNumber(),  
    47 47     $issueObj->getName(), $publicationObj->getName() );  
    48 48 Log::Message($logtext, $User->getUserName(), 155);  
    49 49  
    50   $url = camp_html_article_url($articleCopy, $Language, "edit.php");  
      50 $url = camp_html_article_url($articleCopy, $f_language_id, "edit.php");  
    50 50 header("Location: $url");  
    51 51 exit;  
  • trunk/campsite/implementation/management/priv/articles/translate.php

    r4054 r4085  
    9 9 }  
    10 10  
    11   $Pub = Input::Get('Pub', 'int', 0);  
    12   $Issue = Input::Get('Issue', 'int', 0);  
    13   $Section = Input::Get('Section', 'int', 0);  
    14   $Article = Input::Get('Article', 'int', 0);  
    15   $Language = Input::Get('Language', 'int', 0);  
    16   $sLanguage = Input::Get('sLanguage', 'int', 0);  
      11 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
      12 $f_issue_number = Input::Get('f_issue_number', 'int', 0);  
      13 $f_section_number = Input::Get('f_section_number', 'int', 0);  
      14 $f_article_code = Input::Get('f_article_code', 'string', 0);  
      15 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      16 $f_language_selected = Input::Get('f_language_selected', 'int', 0);  
    17 17 $BackLink = Input::Get('Back', 'string', "/$ADMIN/articles/", true);  
    18 18  
      19 list($articleNumber, $languageId) = split("_", $f_article_code);  
      20  
    19 21 if (!Input::IsValid()) {  
    20 22     camp_html_display_error(getGS('Invalid input: $1', Input::GetErrorString()), $BackLink);  
    21 23     exit;     
    22 24 }  
    23   $publicationObj =& new Publication($Pub);  
      25 $publicationObj =& new Publication($f_publication_id);  
    23 25 if (!$publicationObj->exists()) {  
    24 26     camp_html_display_error(getGS('Publication does not exist.'), $BackLink);  
     
    27 29 }  
    28 30  
    29   $issueObj =& new Issue($Pub, $Language, $Issue);  
      31 $issueObj =& new Issue($f_publication_id, $f_language_id, $f_issue_number);  
    29 31 if (!$issueObj->exists()) {  
    30 32     camp_html_display_error(getGS('No such issue.'), $BackLink);  
     
    33 35 }  
    34 36  
    35   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
      37 $sectionObj =& new Section($f_publication_id, $f_issue_number, $f_language_id, $f_section_number);  
    35 37 if (!$sectionObj->exists()) {  
    36 38     camp_html_display_error(getGS('No such section.'), $BackLink);  
     
    39 41 }  
    40 42  
    41   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      43 $articleObj =& new Article($languageId, $articleNumber);  
    41 43 if (!$articleObj->exists()) {  
    42 44     camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
     
    46 48  
    47 49 if (!$User->hasPermission("AddArticle")) {  
    48       $errorStr = getGS('You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.');  
      50     $errorStr = getGS('You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.');  
    48 50     camp_html_display_error($errorStr, $BackLink);  
    49 51     exit;     
    50 52 }  
    51 53  
    52   $translations = $articleObj->getTranslations();  
    53   foreach ($translations as $translation) {  
    54       $articleNames[] = $translation->getName();  
    55   }  
    56   $outputName = implode(', ', $articleNames);  
    57    
    58 54 $allLanguages = Language::GetLanguages();  
    59 55 $articleLanguages = $articleObj->getLanguages();  
     
    65 61 camp_html_content_top(getGS('Translate article'), $topArray, true, true);  
    66 62 ?>  
    67   <!--<table>  
    68   <tr>  
    69       <td>  
    70           <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1">  
    71           <TR>  
    72               <TD><A HREF="edit.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/back.png" BORDER="0"></A></TD>  
    73               <TD><A HREF="edit.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>" ><B><?php  putGS('Back to article details'); ?></B></A></TD>  
    74           </TR>  
    75           </TABLE>  
    76       </td>  
    77   </tr>  
    78   </table>-->  
    79 63 <P>  
    80   <FORM NAME="dialog" METHOD="POST" ACTION="do_translate.php" >  
    81   <INPUT TYPE="HIDDEN" NAME="Pub" VALUE="<?php  p($Pub); ?>">  
    82   <INPUT TYPE="HIDDEN" NAME="Issue" VALUE="<?php  p($Issue); ?>">  
    83   <INPUT TYPE="HIDDEN" NAME="Section" VALUE="<?php  p($Section); ?>">  
    84   <INPUT TYPE="HIDDEN" NAME="Article" VALUE="<?php  p($Article); ?>">  
    85   <INPUT TYPE="HIDDEN" NAME="Language" VALUE="<?php  p($Language); ?>">  
    86   <INPUT TYPE="HIDDEN" NAME="sLanguage" VALUE="<?php  p($sLanguage); ?>">  
    87   <INPUT TYPE="HIDDEN" NAME="ArticleLanguage" VALUE="<?php  p($articleObj->getLanguageId()); ?>">  
    88   <INPUT TYPE="HIDDEN" NAME="Back" VALUE="<?php echo $BackLink; ?>">  
    89   <CENTER>  
    90   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" ALIGN="CENTER" class="table_input">  
      64 <FORM NAME="dialog" METHOD="POST" ACTION="do_translate.php" onsubmit="return validateForm(this, 0, 1, 0, 1, 8);">  
      65 <INPUT TYPE="HIDDEN" NAME="f_article_code" VALUE="<?php  p($f_article_code); ?>">  
      66 <INPUT TYPE="HIDDEN" NAME="f_language_id" VALUE="<?php  p($f_language_id); ?>">  
      67 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" class="table_input">  
    91 68 <TR>  
    92 69     <TD COLSPAN="2">  
     
    96 73 </TR>  
    97 74 <TR>  
    98       <TD ALIGN="RIGHT" ><?php  putGS("Article"); ?>:</TD>  
    99       <TD><?php p(htmlspecialchars($outputName)); ?></td>  
      75     <TD ALIGN="RIGHT" valign="top"><?php  putGS("Article name"); ?>:</TD>  
      76     <TD><?PHP p(htmlspecialchars($articleObj->getTitle())); ?></td>  
    100 77 </TR>  
    101 78 <TR>  
    102       <TD ALIGN="RIGHT" ><?php putGS("Name"); ?>:</TD>  
      79     <TD ALIGN="RIGHT" ><?php putGS("New article name"); ?>:</TD>  
    102 79     <TD>  
    103       <INPUT TYPE="TEXT" NAME="cName" SIZE="32" MAXLENGTH="64" class="input_text" alt="blank" emsg="<?php putGS('You must complete the $1 field.', getGS('Name')); ?>">  
      80     <INPUT TYPE="TEXT" NAME="f_translation_title" SIZE="32" MAXLENGTH="64" class="input_text" alt="blank" emsg="<?php putGS('You must complete the $1 field.', getGS('Name')); ?>">  
    103 80     </TD>  
    104 81 </TR>  
     
    108 85     <TD ALIGN="RIGHT" ><?php  putGS("Language"); ?>:</TD>  
    109 86     <TD>  
    110       <SELECT NAME="cLanguage" class="input_select">  
      87     <SELECT NAME="f_translation_language" class="input_select" alt="select" emsg="<?php putGS("You must choose a language"); ?>">  
      88     <option></option>  
    111 89     <?php  
    112 90     // Show all the languages that have not yet been translated.  
     
    119 97     asort($displayLanguages);  
    120 98     foreach ($displayLanguages as $tmpLangId => $nativeName) {  
    121           pcomboVar($tmpLangId, '', $nativeName);  
      99         camp_html_select_option($tmpLangId, '', $nativeName);  
    121 99     }  
    122 100     ?>  
     
    126 104 </TR>  
    127 105 <TR>  
    128       <TD ALIGN="RIGHT" ><?php  putGS("Keywords"); ?>:</TD>  
    129       <TD>  
    130           <INPUT TYPE="TEXT" NAME="cKeywords" SIZE="32" MAXLENGTH="255" class="input_text">  
    131       </TD>  
    132   </TR>  
    133   <TR>  
    134 106     <TD COLSPAN="2" align="center">  
    135 107     <INPUT TYPE="submit" NAME="Save" VALUE="<?php  putGS('Save changes'); ?>" class="button">  
    138 110 </TR>  
    139 111 </TABLE>  
    140   </CENTER>  
    141 112 </FORM>  
    142 113 <P>  
  • trunk/campsite/implementation/management/priv/articles/autopublish.php

    r4054 r4085  
    13 13 }  
    14 14  
    15   $Pub = Input::Get('Pub', 'int', 0);  
    16   $Issue = Input::Get('Issue', 'int', 0);  
    17   $Section = Input::Get('Section', 'int', 0);  
    18   $Language = Input::Get('Language', 'int', 0);  
    19   $sLanguage = Input::Get('sLanguage', 'int', 0);  
    20   $Article = Input::Get('Article', 'int', 0);  
      15 $f_publcation_id = Input::Get('f_publication_id', 'int', 0);  
      16 $f_issue_number = Input::Get('f_issue_number', 'int', 0);  
      17 $f_section_number = Input::Get('f_section_number', 'int', 0);  
      18 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      19 $f_language_selected = Input::Get('f_language_selected', 'int', 0);  
      20 $f_article_number = Input::Get('f_article_number', 'int', 0);  
    21 21 $publishTime = Input::Get('publish_time', 'string', '', true);  
    22 22 $BackLink = Input::Get('Back', 'string', "/$ADMIN/articles/edit.php"  
    23                          ."?Pub=$Pub&Issue=$Issue&Section=$Section&sLanguage=$sLanguage&Language=$Language&Article=$Article",  
      23                        ."?f_publcation_id=$f_publcation_id&f_issue_number=$f_issue_number&f_section_number=$f_section_number&f_language_selected=$f_language_selected&f_language_id=$f_language_id&f_article_number=$f_article_number",  
    23 23                        true);  
    24 24  
     
    29 29 }  
    30 30  
    31   $publicationObj =& new Publication($Pub);  
      31 $publicationObj =& new Publication($f_publcation_id);  
    31 31 if (!$publicationObj->exists()) {  
    32 32     camp_html_display_error(getGS('Publication does not exist.'), $BackLink);  
     
    35 35 }  
    36 36  
    37   $issueObj =& new Issue($Pub, $Language, $Issue);  
      37 $issueObj =& new Issue($f_publcation_id, $f_language_id, $f_issue_number);  
    37 37 if (!$issueObj->exists()) {  
    38 38     camp_html_display_error(getGS('Issue does not exist.'), $BackLink);  
     
    41 41 }  
    42 42  
    43   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
      43 $sectionObj =& new Section($f_publcation_id, $f_issue_number, $f_language_id, $f_section_number);  
    43 43 if (!$sectionObj->exists()) {  
    44 44     camp_html_display_error(getGS('Section does not exist.'), $BackLink);  
     
    47 47 }  
    48 48  
    49   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      49 $articleObj =& new Article($f_language_selected, $f_article_number);  
    49 49 if (!$articleObj->exists()) {  
    50 50     camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
     
    53 53 }  
    54 54  
    55   $languageObj =& new Language($Language);  
    56   $sLanguageObj =& new Language($sLanguage);  
    57   $articleEvents = ArticlePublish::GetArticleEvents($Article, $sLanguage);  
      55 $languageObj =& new Language($f_language_id);  
      56 $sLanguageObj =& new Language($f_language_selected);  
      57 $articleEvents = ArticlePublish::GetArticleEvents($f_article_number, $f_language_selected);  
    58 58  
    59 59 $topArray = array('Pub' => $publicationObj, 'Issue' => $issueObj,  
     
    69 69     $sectionPageAction = '';  
    70 70     if ($publishTime != "") {  
    71           $articlePublishObj =& new ArticlePublish($Article, $sLanguage, $publishTime);  
      71         $articlePublishObj =& new ArticlePublish($f_article_number, $f_language_selected, $publishTime);  
    71 71         if ($articlePublishObj->exists()) {  
    72 72             $publishAction = $articlePublishObj->getPublishAction();  
     
    88 88         <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1">  
    89 89         <TR>  
    90               <TD><A HREF="edit.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/back.png" BORDER="0"></A></TD>  
    91               <TD><A HREF="edit.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>" ><B><?php  putGS('Back to Edit Article'); ?></B></A></TD>  
      90             <TD><A HREF="edit.php?f_publcation_id=<?php  p($f_publcation_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_article_number=<?php  p($f_article_number); ?>&f_language_id=<?php  p($f_language_id); ?>&f_language_selected=<?php  p($f_language_selected); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/back.png" BORDER="0"></A></TD>  
      91             <TD><A HREF="edit.php?f_publcation_id=<?php  p($f_publcation_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_article_number=<?php  p($f_article_number); ?>&f_language_id=<?php  p($f_language_id); ?>&f_language_selected=<?php  p($f_language_selected); ?>" ><B><?php  putGS('Back to Edit Article'); ?></B></A></TD>  
    92 92         </TR>  
    93 93         </TABLE>  
     
    104 104         </TD>  
    105 105     </TR>  
    106       <INPUT TYPE="HIDDEN" NAME="Pub" VALUE="<?php echo $Pub; ?>">  
    107       <INPUT TYPE="HIDDEN" NAME="Issue" VALUE="<?php echo $Issue; ?>">  
    108       <INPUT TYPE="HIDDEN" NAME="Section" VALUE="<?php echo $Section; ?>">  
    109       <INPUT TYPE="HIDDEN" NAME="Article" VALUE="<?php echo $Article; ?>">  
    110       <INPUT TYPE="HIDDEN" NAME="Language" VALUE="<?php echo $Language; ?>">  
    111       <INPUT TYPE="HIDDEN" NAME="sLanguage" VALUE="<?php echo $sLanguage; ?>">  
      106     <INPUT TYPE="HIDDEN" NAME="f_publication_id" VALUE="<?php echo $f_publcation_id; ?>">  
      107     <INPUT TYPE="HIDDEN" NAME="f_issue_number" VALUE="<?php echo $f_issue_number; ?>">  
      108     <INPUT TYPE="HIDDEN" NAME="f_section_number" VALUE="<?php echo $f_section_number; ?>">  
      109     <INPUT TYPE="HIDDEN" NAME="f_article_number" VALUE="<?php echo $f_article_number; ?>">  
      110     <INPUT TYPE="HIDDEN" NAME="f_language_id" VALUE="<?php echo $f_language_id; ?>">  
      111     <INPUT TYPE="HIDDEN" NAME="f_language_selected" VALUE="<?php echo $f_language_selected; ?>">  
    112 112     <INPUT type="hidden" name="Back" value="<?php echo $BackLink; ?>">  
    113 113     <TR>  
     
    187 187         ?>  <TR <?php  if ($color) { $color=0; ?>class="list_row_even"<?php  } else { $color=1; ?>class="list_row_odd"<?php  } ?>>  
    188 188         <TD>  
    189               <A HREF="/<?php echo $ADMIN; ?>/articles/autopublish.php?Pub=<?php p($Pub); ?>&Issue=<?php p($Issue); ?>&Section=<?php p($Section); ?>&Article=<?php p($Article); ?>&Language=<?php p($Language); ?>&sLanguage=<?php p($sLanguage); ?>&publish_time=<?php echo $url_publish_time; ?>"><?php p(htmlspecialchars($event->getActionTime())); ?></A>  
      189             <A HREF="/<?php echo $ADMIN; ?>/articles/autopublish.php?f_publcation_id=<?php p($f_publcation_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_article_number=<?php p($f_article_number); ?>&f_language_id=<?php p($f_language_id); ?>&f_language_selected=<?php p($f_language_selected); ?>&publish_time=<?php echo $url_publish_time; ?>"><?php p(htmlspecialchars($event->getActionTime())); ?></A>  
    189 189         </TD>  
    190 190          
     
    227 227          
    228 228         <TD ALIGN="CENTER">  
    229               <A HREF="/<?php echo $ADMIN; ?>/articles/autopublish_del.php?Pub=<?php p($Pub); ?>&Issue=<?php p($Issue); ?>&Section=<?php p($Section); ?>&Article=<?php p($Article); ?>&Language=<?php p($Language); ?>&sLanguage=<?php p($sLanguage); ?>&publish_time=<?php echo $url_publish_time; ?>&Back=<?php p(urlencode($BackLink)); ?>" onclick="return confirm('<?php putGS("Are you sure you want to delete this scheduled action?"); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/x.gif" BORDER="0" ALT="<?php putGS('Delete'); ?>"></A>  
      229             <A HREF="/<?php echo $ADMIN; ?>/articles/autopublish_del.php?f_publcation_id=<?php p($f_publcation_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_article_number=<?php p($f_article_number); ?>&f_language_id=<?php p($f_language_id); ?>&f_language_selected=<?php p($f_language_selected); ?>&f_action_id=<?php echo $event->getArticlePublishId(); ?>&Back=<?php p(urlencode($BackLink)); ?>" onclick="return confirm('<?php putGS("Are you sure you want to delete this scheduled action?"); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0" ALT="<?php putGS('Delete'); ?>"></A>  
    229 229         </TD>  
    230 230     </TR>  
    252 252     <TR>  
    253 253         <TD COLSPAN="2" align="center">  
    254               <INPUT TYPE="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/edit.php?Pub=<?php p($Pub); ?>&Issue=<?php p($Issue); ?>&Section=<?php p($Section); ?>&Article=<?php p($Article); ?>&Language=<?php p($Language); ?>&sLanguage=<?php p($sLanguage); ?>'" class="button">  
      254             <INPUT TYPE="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/edit.php?f_publcation_id=<?php p($f_publcation_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_article_number=<?php p($f_article_number); ?>&f_language_id=<?php p($f_language_id); ?>&f_language_selected=<?php p($f_language_selected); ?>'" class="button">  
    254 254         </TD>  
    255 255     </TR>  
  • trunk/campsite/implementation/management/priv/articles/do_status.php

    r3903 r4085  
    10 10 }  
    11 11  
    12   $Pub = Input::Get('Pub', 'int', 0);  
    13   $Issue = Input::Get('Issue', 'int', 0);  
    14   $Section = Input::Get('Section', 'int', 0);  
      12 //$Pub = Input::Get('Pub', 'int', 0);  
      13 //$Issue = Input::Get('Issue', 'int', 0);  
      14 //$Section = Input::Get('Section', 'int', 0);  
    15 15 $Language = Input::Get('Language', 'int', 0);  
    16 16 $Article = Input::Get('Article', 'int', 0);  
    17   $sLanguage = Input::Get('sLanguage', 'int', 0);  
      17 //$sLanguage = Input::Get('sLanguage', 'int', 0);  
    17 17 $Status = strtoupper(Input::Get('Status', 'string', 'N'));  
    18 18 $BackLink = Input::Get('Back', 'string', "/$ADMIN/articles/index.php", true);  
     
    29 29 }  
    30 30  
    31   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      31 $articleObj =& new Article($sLanguage, $Article);  
    31 31 if (!$articleObj->exists()) {  
    32 32     camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
    33 33     exit;         
    34 34 }  
    35   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    36   if (!$sectionObj->exists()) {  
    37       camp_html_display_error(getGS('Section does not exist.'), $BackLink);     
    38   }  
    39   $issueObj =& new Issue($Pub, $Language, $Issue);  
    40   if (!$issueObj->exists()) {  
    41       camp_html_display_error(getGS('Issue does not exist.'), $BackLink);  
    42   }  
    43   $publicationObj =& new Publication($Pub);  
    44   if (!$publicationObj->exists()) {  
    45       camp_html_display_error(getGS('Publication does not exist.'), $BackLink);     
    46   }  
      35 //$sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
      36 //if (!$sectionObj->exists()) {  
      37 //  camp_html_display_error(getGS('Section does not exist.'), $BackLink);     
      38 //}  
      39 //$issueObj =& new Issue($Pub, $Language, $Issue);  
      40 //if (!$issueObj->exists()) {  
      41 //  camp_html_display_error(getGS('Issue does not exist.'), $BackLink);  
      42 //}  
      43 //$publicationObj =& new Publication($Pub);  
      44 //if (!$publicationObj->exists()) {  
      45 //  camp_html_display_error(getGS('Publication does not exist.'), $BackLink);     
      46 //}  
    47 47  
    48 48 $languageObj =& new Language($Language);  
     
    59 59 }  
    60 60 if (!$access) {  
    61       $errorStr = getGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users.");  
      61     $errorStr = getGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users.");  
    61 61     camp_html_display_error($errorStr, $BackLink);  
    62 62     exit;     
    66 66 $articleObj->setPublished($Status);  
    67 67  
    68   $logtext = getGS('Article $1 status from $2. $3 from $4. $5 ($6) of $7 changed', $articleObj->getTitle(), $sectionObj->getSectionId(), $sectionObj->getName(), $issueObj->getIssueId(), $issueObj->getName(), $languageObj->getName(), $publicationObj->getName() );  
    69   Log::Message($logtext, $User->getUserName(), 35);  
    70    
    71 68 header('Location: '.$BackLink);  
    72 69 exit;  
  • trunk/campsite/implementation/management/priv/articles/do_edit.php

    r4054 r4085  
    202 202  
    203 203 // Fetch article  
    204   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      204 $articleObj =& new Article($sLanguage, $Article);  
    204 204 if (!$articleObj->exists()) {  
    205 205     camp_html_display_error(getGS('No such article.'), $BackLink);  
    220 220  
    221 221 if (!$articleObj->userCanModify($User)) {  
    222       $errorStr = getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.");  
      222     $errorStr = getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.");  
    222 222     camp_html_display_error($errorStr, $BackLink);  
    223 223     exit;  
  • trunk/campsite/implementation/management/priv/articles/index.php

    r4067 r4085  
    3 3 require_once($_SERVER['DOCUMENT_ROOT']. '/classes/DbObjectArray.php');  
    4 4 require_once($_SERVER['DOCUMENT_ROOT']. '/classes/ArticlePublish.php');  
      5 require_once($_SERVER['DOCUMENT_ROOT']. '/include/HTTP_Session/Session.php');  
      6  
      7 HTTP_Session::start();  
    5 8  
    6 9 list($access, $User) = check_basic_access($_REQUEST);  
     
    10 13 }  
    11 14  
    12   $Pub = Input::Get('Pub', 'int', 0);  
    13   $Issue = Input::Get('Issue', 'int', 0);  
    14   $Section = Input::Get('Section', 'int', 0);  
    15   $Language = Input::Get('Language', 'int', 0);  
    16   $sLanguage = Input::Get('sLanguage', 'int', 0, true);  
    17   $ArticleOffset = Input::Get('ArtOffs', 'int', 0, true);  
    18   $ArticlesPerPage = Input::Get('lpp', 'int', 10, true);  
      15 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
      16 $f_issue_number = Input::Get('f_issue_number', 'int', 0);  
      17 $f_section_number = Input::Get('f_section_number', 'int', 0);  
      18 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      19 $f_language_selected = Input::Get('f_language_selected', 'int', 0, true);  
      20 $f_article_offset = Input::Get('f_article_offset', 'int', 0, true);  
      21 $ArticlesPerPage = 20;  
      22  
      23 //$f_articles_per_page = HTTP_Session::get('campsite_articles_per_page', $f_articles_per_page);  
      24 //$f_article_offset = HTTP_Session::get('campsite_articles_per_page', $f_article_offset);  
    19 25  
    20 26 if (!Input::IsValid()) {  
     
    23 29 }  
    24 30  
    25   if ($ArticleOffset < 0) {  
    26       $ArticleOffset = 0;  
      31 if ($f_article_offset < 0) {  
      32     $f_article_offset = 0;  
    27 33 }  
    28 34  
    29   $publicationObj =& new Publication($Pub);  
      35 $sectionObj =& new Section($f_publication_id, $f_issue_number, $f_language_id, $f_section_number);  
      36 if (!$sectionObj->exists()) {  
      37     camp_html_display_error(getGS('Section does not exist.'));  
      38     exit;         
      39 }  
      40  
      41 $publicationObj =& new Publication($f_publication_id);  
    30 42 if (!$publicationObj->exists()) {  
    31 43     camp_html_display_error(getGS('Publication does not exist.'));  
     
    33 45 }  
    34 46  
    35   $issueObj =& new Issue($Pub, $Language, $Issue);  
      47 $issueObj =& new Issue($f_publication_id, $f_language_id, $f_issue_number);  
    35 47 if (!$issueObj->exists()) {  
    36 48     camp_html_display_error(getGS('Issue does not exist.'));  
     
    39 51 }  
    40 52  
    41   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    42   if (!$sectionObj->exists()) {  
    43       camp_html_display_error(getGS('Section does not exist.'), $BackLink);  
    44       exit;         
    45   }  
    46    
    47   $languageObj =& new Language($Language);  
    48   $sLanguageObj =& new Language($sLanguage);  
    49 53 $allArticleLanguages = Article::GetAllLanguages();  
    50 54  
    51   if ($sLanguage) {  
      55 if ($f_language_selected) {  
    51 55     // Only show a specific language.  
    52       $allArticles = Article::GetArticles($Pub, $Issue, $Section, $sLanguage, null, $Language,  
    53           $ArticlesPerPage, $ArticleOffset);  
    54       $totalArticles = count(Article::GetArticles($Pub, $Issue, $Section, $sLanguage));  
      56     $allArticles = Article::GetArticles($f_publication_id, $f_issue_number,  
      57         $f_section_number, $f_language_selected, null, $f_language_id,  
      58         $ArticlesPerPage, $f_article_offset);  
      59     $totalArticles = count(Article::GetArticles($f_publication_id,  
      60         $f_issue_number, $f_section_number, $f_language_selected));  
    55 61     $numUniqueArticles = $totalArticles;  
    56 62     $numUniqueArticlesDisplayed = count($allArticles);  
    57 63 } else {  
    58 64     // Show articles in all languages.  
    59       $allArticles = Article::GetArticles($Pub, $Issue, $Section, null, null, $Language,  
    60           $ArticlesPerPage, $ArticleOffset, true);  
    61       $totalArticles = count(Article::GetArticles($Pub, $Issue, $Section, null));  
    62       $numUniqueArticles = Article::GetNumUniqueArticles($Pub, $Issue, $Section);  
      65     $allArticles = Article::GetArticles($f_publication_id, $f_issue_number,  
      66         $f_section_number, null, null, $f_language_id,  
      67         $ArticlesPerPage, $f_article_offset, true);  
      68     $totalArticles = count(Article::GetArticles($f_publication_id, $f_issue_number, $f_section_number, null));  
      69     $numUniqueArticles = Article::GetNumUniqueArticles($f_publication_id, $f_issue_number, $f_section_number);  
    63 70     $numUniqueArticlesDisplayed = count(array_unique(DbObjectArray::GetColumn($allArticles, 'Number')));  
    64 71 }  
    65 72  
    66   $previousArticleId = 0;  
      73 $previousArticleNumber = 0;  
    66 73  
    67 74 $topArray = array('Pub' => $publicationObj, 'Issue' => $issueObj,  
     
    72 79 ?>  
    73 80 <P>  
    74   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0">  
      81 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="0" class="action_buttons">  
    74 81 <TR>  
    75 82 <?php if ($User->hasPermission('AddArticle')) { ?>  
     
    78 85         <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1">  
    79 86         <TR>  
    80               <TD><A HREF="add.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Language=<?php  p($Language); ?>&Back=<?php p(urlencode($_SERVER['REQUEST_URI'])); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add_article.png" BORDER="0"></A></TD>  
    81               <TD><A HREF="add.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Language=<?php  p($Language); ?>&Back=<?php  p(urlencode($_SERVER['REQUEST_URI'])); ?>" ><B><?php  putGS("Add new article"); ?></B></A></TD>  
      87             <TD><A HREF="add.php?f_publication_id=<?php p($f_publication_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_language_id=<?php p($f_language_id); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD>  
      88             <TD><A HREF="add.php?f_publication_id=<?php p($f_publication_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_language_id=<?php p($f_language_id); ?>" ><B><?php  putGS("Add new article"); ?></B></A></TD>  
    82 89         </TR>  
    83 90         </TABLE>  
    84 91     </TD>  
    85 92 <?php  } ?>  
    86       <TD ALIGN="left" style="padding-left: 20px;">  
    87           <FORM METHOD="GET" ACTION="index.php" NAME="">  
    88           <INPUT TYPE="HIDDEN" NAME="Pub" VALUE="<?php  p($Pub); ?>">  
    89           <INPUT TYPE="HIDDEN" NAME="Issue" VALUE="<?php  p($Issue); ?>">  
    90           <INPUT TYPE="HIDDEN" NAME="Section" VALUE="<?php  p($Section); ?>">  
    91           <INPUT TYPE="HIDDEN" NAME="Language" VALUE="<?php  p($Language); ?>">  
    92           <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="3" class="table_input">  
      93 </tr>  
      94 </TABLE>  
      95 <p>  
      96  
      97 <script>  
      98 function checkAll(field)  
      99 {  
      100     if (field) {  
      101         for (i = 0; i < field.length; i++) {  
      102             field[i].checked = true ;  
      103         }  
      104     }  
      105 }  
      106  
      107 function uncheckAll(field)  
      108 {  
      109     if (field) {  
      110         for (i = 0; i < field.length; i++) {  
      111             field[i].checked = false ;  
      112         }  
      113     }  
      114 }  
      115 </script>  
      116 <div style="position: fixed; top: 120px;">  
      117 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="3" class="table_input" style="background-color: #D5C3DF; border-color: #A35ACF;">  
      118 <TR>  
      119     <TD>  
      120         <TABLE cellpadding="0" cellspacing="0">  
    93 121         <TR>  
    94               <TD><?php  putGS('Language'); ?>:</TD>  
    95               <TD valign="middle">  
    96                   <SELECT NAME="sLanguage" class="input_select">  
    97                   <option></option>  
    98                   <?php  
    99                   foreach ($allArticleLanguages as $languageItem) {  
    100                       echo '<OPTION value="'.$languageItem->getLanguageId().'"' ;  
    101                       if ($languageItem->getLanguageId() == $sLanguage) {  
    102                           echo " selected";  
      122             <TD ALIGN="left">  
      123                 <FORM METHOD="GET" ACTION="index.php" NAME="selected_language">  
      124                 <INPUT TYPE="HIDDEN" NAME="f_publication_id" VALUE="<?php p($f_publication_id); ?>">  
      125                 <INPUT TYPE="HIDDEN" NAME="f_issue_number" VALUE="<?php p($f_issue_number); ?>">  
      126                 <INPUT TYPE="HIDDEN" NAME="f_section_number" VALUE="<?php p($f_section_number); ?>">  
      127                 <INPUT TYPE="HIDDEN" NAME="f_language_id" VALUE="<?php p($f_language_id); ?>">  
      128                 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="3" >  
      129                 <TR>  
      130                     <TD><?php  putGS('Language'); ?>:</TD>  
      131                     <TD valign="middle">  
      132                         <SELECT NAME="f_language_selected" class="input_select" onchange="this.form.submit();">  
      133                         <option><?php putGS("All"); ?></option>  
      134                         <?php  
      135                         foreach ($allArticleLanguages as $languageItem) {  
      136                             echo '<OPTION value="'.$languageItem->getLanguageId().'"' ;  
      137                             if ($languageItem->getLanguageId() == $f_language_selected) {  
      138                                 echo " selected";  
      139                             }  
      140                             echo '>'.htmlspecialchars($languageItem->getName()).'</option>';  
      141                         } ?>  
      142                         </SELECT>  
      143                     </TD>  
      144                 </TR>  
      145                 </TABLE>  
      146                 </FORM>  
      147             </TD>  
      148             <TD style="padding-left: 20px;">  
      149                 <script>  
      150                 function action_selected(dropdownElement)  
      151                 {  
      152                     // Verify that at least one checkbox has been selected.  
      153                     checkboxes = document.forms.article_list["f_article_code[]"];  
      154                     if (checkboxes) {  
      155                         isValid = false;  
      156                         numCheckboxesChecked = 0;  
      157                         // Special case for single checkbox  
      158                         // (when there is only one article in the section).  
      159                         if (!checkboxes.length) {  
      160                             isValid = checkboxes.checked;  
      161                             numCheckboxesChecked = isValid ? 1 : 0;  
      162                         }  
      163                         else {  
      164                             // Multiple checkboxes  
      165                             for (var index = 0; index < checkboxes.length; index++) {  
      166                                 if (checkboxes[index].checked) {  
      167                                     isValid = true;  
      168                                     numCheckboxesChecked++;  
      169                                 }  
      170                             }  
      171                         }  
      172                         if (!isValid) {  
      173                             alert("<?php putGS("You must select at least one article to perform an action."); ?>");  
      174                             dropdownElement.options[0].selected = true;  
      175                             return;  
      176                         }  
    103 177                     }  
    104                       echo '>'.htmlspecialchars($languageItem->getName()).'</option>';  
    105                   } ?>  
      178                     else {  
      179                         dropdownElement.options[0].selected = true;  
      180                         return;  
      181                     }  
      182                              
      183                     // Get the index of the "delete" option.  
      184                     deleteOptionIndex = -1;  
      185                     translateOptionIndex = -1;  
      186                     for (var index = 0; index < dropdownElement.options.length; index++) {  
      187                         if (dropdownElement.options[index].value == "delete") {  
      188                             deleteOptionIndex = index;  
      189                         }  
      190                         if (dropdownElement.options[index].value == "translate") {  
      191                             translateOptionIndex = index;  
      192                         }  
      193                     }  
      194                      
      195                     // if the user has selected the "delete" option  
      196                     if (dropdownElement.selectedIndex == deleteOptionIndex) {  
      197                         ok = confirm("<?php putGS("Are you sure you want to delete the selected articles?"); ?>");  
      198                         if (!ok) {  
      199                             dropdownElement.options[0].selected = true;  
      200                             return;  
      201                         }  
      202                     }  
      203                      
      204                     // if the user selected the "translate" option  
      205                     if ( (dropdownElement.selectedIndex == translateOptionIndex)  
      206                          && (numCheckboxesChecked > 1) ) {  
      207                         alert("<?php putGS("You may only translate one article at a time."); ?>");  
      208                         dropdownElement.options[0].selected = true;  
      209                         return;  
      210                     }  
      211                      
      212                     // do the action if it isnt the first or second option  
      213                     if ( (dropdownElement.selectedIndex != 0) &&  (dropdownElement.selectedIndex != 1) ) {  
      214                         dropdownElement.form.submit();  
      215                     }  
      216                 }  
      217                 </script>  
      218                 <FORM name="article_list" action="do_article_list_action.php" method="POST">  
      219                 <INPUT TYPE="HIDDEN" NAME="f_publication_id" VALUE="<?php  p($f_publication_id); ?>">  
      220                 <INPUT TYPE="HIDDEN" NAME="f_issue_number" VALUE="<?php  p($f_issue_number); ?>">  
      221                 <INPUT TYPE="HIDDEN" NAME="f_section_number" VALUE="<?php  p($f_section_number); ?>">  
      222                 <INPUT TYPE="HIDDEN" NAME="f_language_id" VALUE="<?php  p($f_language_id); ?>">  
      223                 <INPUT TYPE="HIDDEN" NAME="f_language_selected" VALUE="<?php  p($f_language_selected); ?>">  
      224                 <SELECT name="f_article_list_action" class="input_select" onchange="action_selected(this);">  
      225                 <OPTION value=""><?php putGS("Actions"); ?>...</OPTION>  
      226                 <OPTION value="">-----------------------</OPTION>  
      227                  
      228                 <?php if ($User->hasPermission('Publish')) { ?>  
      229                 <OPTION value="workflow_publish"><?php putGS("Workflow: Publish"); ?></OPTION>  
      230                 <?php } ?>  
      231                  
      232                 <?php if ($User->hasPermission('ChangeArticle')) { ?>  
      233                 <OPTION value="workflow_submit"><?php putGS("Workflow: Submit"); ?></OPTION>  
      234                 <?php } ?>  
      235  
      236                 <?php if ($User->hasPermission('Publish')) { ?>  
      237                 <OPTION value="workflow_new"><?php putGS("Workflow: Set New"); ?></OPTION>  
      238                 <?php } ?>  
      239                  
      240                 <OPTION value="schedule_publish"><?php putGS("Schedule Publish"); ?></OPTION>  
      241                 <OPTION value="unlock"><?php putGS("Unlock"); ?></OPTION>  
      242                  
      243                 <?php  if ($User->hasPermission('DeleteArticle')) { ?>  
      244                 <OPTION value="delete"><?php putGS("Delete"); ?></OPTION>  
      245                 <?php } ?>  
      246                  
      247                 <?php  if ($User->hasPermission('AddArticle')) { ?>  
      248                 <OPTION value="copy"><?php putGS("Copy"); ?></OPTION>  
      249                 <OPTION value="copy_interactive"><?php putGS("Copy to another section"); ?></OPTION>  
      250                 <OPTION value="translate"><?php putGS("Translate"); ?></OPTION>  
      251                 <?php } ?>  
      252                  
      253                 <OPTION value="move"><?php putGS("Reorder"); ?></OPTION>  
      254                 <OPTION value="preview"><?php putGS("Preview"); ?></OPTION>  
    106 255                 </SELECT>  
    107 256             </TD>  
    108               <TD><INPUT TYPE="submit" NAME="Search" VALUE="<?php  putGS('Search'); ?>" class="button"></TD>  
      257              
      258             <TD style="padding-left: 5px; font-weight: bold;">  
      259                 <input type="button" class="button" value="<?php putGS("Select All"); ?>" onclick="checkAll(document.article_list['f_article_code[]']);">  
      260                 <input type="button" class="button" value="<?php putGS("Select None"); ?>" onclick="uncheckAll(document.article_list['f_article_code[]']);">  
      261             </TD>  
    109 262         </TR>  
    110 263         </TABLE>  
    111           </FORM>  
    112 264     </TD>  
    113   </tr>  
      265      
      266 </TR>  
    114 267 </TABLE>  
    115    
      268 </div>  
    115 268 <P>  
    116 269 <?php  
     
    120 273     $color = 0;  
    121 274 ?>  
    122   <TABLE BORDER="0" CELLSPACING="1" CELLPADDING="3" class="table_list">  
      275 <TABLE BORDER="0" CELLSPACING="1" CELLPADDING="3" class="table_list" style="padding-top: 40px;">  
    122 275 <TR class="table_list_header">  
      276     <TD> </TD>  
    123 277     <TD ALIGN="LEFT" VALIGN="TOP"><?php  putGS("Name <SMALL>(click to edit)</SMALL>"); ?></TD>  
    124 278     <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Type"); ?></TD>  
      279     <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Author"); ?></TD>  
    125 280     <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Status"); ?></TD>  
    126 281     <?php if ($User->hasPermission('Publish')) { ?>  
    127       <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Order"); ?></TD>  
    128 282     <TD ALIGN="center" VALIGN="TOP"><?php  echo str_replace(' ', '<br>', getGS("Scheduled Publishing")); ?></TD>  
    129 283     <?php } ?>   
    130       <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Preview"); ?></TD>  
    131       <?php  if ($User->hasPermission('AddArticle')) { ?>  
    132       <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Translate"); ?></TD>  
    133       <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Duplicate"); ?></TD>  
    134       <?php  } ?>  
    135       <?php  if ($User->hasPermission('DeleteArticle')) { ?>  
    136       <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Delete"); ?></TD>  
    137       <?php  } ?>  
      284     <TD ALIGN="center" VALIGN="TOP"><?php  echo str_replace(' ', '<br>', getGS("On Front Page")); ?></TD>  
      285     <TD ALIGN="center" VALIGN="TOP"><?php  echo str_replace(' ', '<br>', getGS("On Section Page")); ?></TD>  
      286     <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Images"); ?></TD>  
      287     <TD ALIGN="center" VALIGN="TOP"><?php  putGS("Topics"); ?></TD>  
    138 288 </TR>  
    139 289 <?php  
    140 290 $uniqueArticleCounter = 0;  
    141 291 foreach ($allArticles as $articleObj) {  
    142       if ($articleObj->getArticleId() != $previousArticleId) {  
      292     if ($articleObj->getArticleNumber() != $previousArticleNumber) {  
    142 292         $uniqueArticleCounter++;  
    143 293     }  
     
    162 312     ?>   
    163 313     <TR class="<?php p($rowClass); ?>">  
    164           <TD <?php if ($articleObj->getArticleId() == $previousArticleId) { ?>class="translation_indent"<?php } ?>>  
      314         <TD>  
      315             <input type="checkbox" value="<?php p($articleObj->getArticleNumber().'_'.$articleObj->getLanguageId()); ?>" name="f_article_code[]" class="input_checkbox">  
      316         </TD>  
      317         <TD <?php if ($articleObj->getArticleNumber() == $previousArticleNumber) { ?>class="translation_indent"<?php } ?>>  
    165 318          
    166 319         <?php  
    167           if ($articleObj->isLocked() && ($timeDiff['days'] <= 0) && ($articleObj->getLockedByUser() != $User->getId())) {  
      320         if ($articleObj->getArticleNumber() != $previousArticleNumber) {  
      321             echo $f_article_offset + $uniqueArticleCounter.". ";  
      322         }  
      323         // Is article locked?  
      324         //if ($articleObj->isLocked() && ($timeDiff['days'] <= 0) && ($articleObj->getLockedByUser() != $User->getId())) {  
      325         if ($articleObj->isLocked() && ($timeDiff['days'] <= 0)) {  
    168 326             $lockUserObj =& new User($articleObj->getLockedByUser());  
    169 327             if ($timeDiff['hours'] > 0) {  
     
    187 345         $userCanEdit = $articleObj->userCanModify($User);  
    188 346         if ($userCanEdit) { ?>  
    189           <A HREF="/<?php echo $ADMIN; ?>/articles/edit.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php p($articleObj->getArticleId()); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php p($articleObj->getLanguageId()); ?>"><?php } ?><?php  p(htmlspecialchars($articleObj->getTitle())); ?> <?php if ($userCanEdit) { ?></A><?php } ?> (<?php p(htmlspecialchars($articleObj->getLanguageName())); ?>)  
      347         <A HREF="/<?php echo $ADMIN; ?>/articles/edit.php?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_article_number=<?php p($articleObj->getArticleNumber()); ?>&f_language_id=<?php  p($f_language_id); ?>&f_language_selected=<?php p($articleObj->getLanguageId()); ?>"><?php } ?><?php  p(htmlspecialchars($articleObj->getTitle())); ?> <?php if ($userCanEdit) { ?></A><?php } ?> (<?php p(htmlspecialchars($articleObj->getLanguageName())); ?>)  
    189 347         </TD>  
    190 348         <TD ALIGN="RIGHT">  
     
    193 351         </TD>  
    194 352  
      353         <TD ALIGN="RIGHT">  
      354             <?php  
      355             $articleCreator =& new User($articleObj->getUserId());  
      356             p(htmlspecialchars($articleCreator->getName()));  ?>  
      357         </TD>  
      358  
    195 359         <TD ALIGN="CENTER">  
    196 360             <?php  
    197               $statusLink = "<A HREF=\"/$ADMIN/articles/status.php?Pub=". $Pub  
    198                   .'&Issue='.$Issue.'&Section='.$Section.'&Article='.$articleObj->getArticleId()  
    199                   .'&Language='.$Language.'&sLanguage='.$articleObj->getLanguageId()  
    200                   .'&Back='.urlencode($_SERVER['REQUEST_URI']).'">';  
      361             $statusLink = "<A HREF=\"/$ADMIN/articles/status.php?f_publication_id=". $f_publication_id  
      362                 .'&f_issue_number='.$f_issue_number  
      363                 .'&f_section_number='.$f_section_number  
      364                 .'&f_article_number='.$articleObj->getArticleNumber()  
      365                 .'&f_language_id='.$f_language_id  
      366                 .'&f_language_selected='.$articleObj->getLanguageId().'">';  
    201 367             if ($articleObj->getPublished() == "Y") {  
    202 368                 $statusWord = "Published";  
     
    230 396         </TD>  
    231 397          
    232           <?php  
    233           // The MOVE links   
    234           if ($User->hasPermission('Publish')) {  
    235               if (($articleObj->getArticleId() == $previousArticleId) || ($numUniqueArticles <= 1))  {  
    236                   ?>  
    237                   <TD ALIGN="CENTER" valign="middle" NOWRAP></TD>  
    238                   <?php  
    239               }  
    240               else {  
    241                   ?>  
    242                   <TD ALIGN="right" valign="middle" NOWRAP>  
    243                       <table cellpadding="0" cellspacing="0">  
    244                       <tr>  
    245                           <td width="22px">  
    246                               <?php if (($ArticleOffset > 0) || ($uniqueArticleCounter != 1)) { ?>  
    247                                   <A HREF="/<?php echo $ADMIN; ?>/articles/do_move.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php p($articleObj->getArticleId()); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php p($articleObj->getLanguageId()); ?>&ArticleLanguage=<?php p($articleObj->getLanguageId()); ?>&move=up_rel&pos=1&ArtOffs=<?php p($ArticleOffset); ?>&Back=<?php p(urlencode($_SERVER['REQUEST_URI'])); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/up.png" width="16" height="16" border="0"></A>  
    248                               <?php } ?>  
    249                           </td>  
    250                           <td width="22px">  
    251                               <?php if (($uniqueArticleCounter+$ArticleOffset) < $numUniqueArticles) { ?>  
    252                                   <A HREF="/<?php echo $ADMIN; ?>/articles/do_move.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php p($articleObj->getArticleId()); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php p($articleObj->getLanguageId()); ?>&ArticleLanguage=<?php p($articleObj->getLanguageId()); ?>&move=down_rel&pos=1&ArtOffs=<?php p($ArticleOffset); ?>&Back=<?php p(urlencode($_SERVER['REQUEST_URI'])); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/down.png" width="16" height="16" border="0" style="padding-left: 3px; padding-right: 3px;"></A>  
    253                               <?php } ?>  
    254                           </td>  
    255                           <form method="GET" action="do_move.php">  
    256                           <input type="hidden" name="Pub" value="<?php p($Pub); ?>">  
    257                           <input type="hidden" name="Issue" value="<?php p($Issue); ?>">  
    258                           <input type="hidden" name="Section" value="<?php p($Section); ?>">  
    259                           <input type="hidden" name="Language" value="<?php p($Language); ?>">  
    260                           <input type="hidden" name="sLanguage" value="<?php p($sLanguage); ?>">  
    261                           <input type="hidden" name="ArticleLanguage" value="<?php p($articleObj->getLanguageId()); ?>">  
    262                           <input type="hidden" name="Article" value="<?php p($articleObj->getArticleId()); ?>">  
    263                           <input type="hidden" name="ArtOffs" value="<?php p($ArticleOffset); ?>">  
    264                           <input type="hidden" name="Back" value="<?php p($_SERVER['REQUEST_URI']); ?>">  
    265                           <input type="hidden" name="move" value="abs">  
    266                           <td>  
    267                               <select name="pos" onChange="this.form.submit();" class="input_select">  
    268                               <?php  
    269                               for ($j = 1; $j <= $numUniqueArticles; $j++) {  
    270                                   if (($ArticleOffset + $uniqueArticleCounter) == $j) {  
    271                                       echo "<option value=\"$j\" selected>$j</option>\n";  
    272                                   } else {  
    273                                       echo "<option value=\"$j\">$j</option>\n";  
    274                                   }  
    275                               }  
    276                               ?>  
    277                               </select>  
    278                           </td>  
    279                           </form>  
    280                       </tr>  
    281                       </table>  
    282                   </TD>  
    283                   <?php   
    284                   }  
    285           } // if user->hasPermission('publish')  
    286           ?>  
    287            
    288 398         <?php if ($User->hasPermission('Publish')) { ?>  
    289 399         <TD ALIGN="CENTER">  
    290 400             <?php if ($articleObj->getPublished() != 'N') {  
    291                   $events = ArticlePublish::GetArticleEvents($articleObj->getArticleId(),  
      401                 $events = ArticlePublish::GetArticleEvents($articleObj->getArticleNumber(),  
    291 401                     $articleObj->getLanguageId());?>  
    292               <A HREF="/<?php echo $ADMIN; ?>/articles/autopublish.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php p($articleObj->getArticleId()); ?>&Language=<?php  p($Language);?>&sLanguage=<?php p($articleObj->getLanguageId()); ?>&Back=<?php p(urlencode($_SERVER['REQUEST_URI'])); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/<?php p((count($events) > 0) ? 'automatic_publishing_active.png':'automatic_publishing.png'); ?>" alt="<?php  putGS("Scheduled Publishing"); ?>" title="<?php  putGS("Scheduled Publishing"); ?>" border="0" width="22" height="22"></A>  
      402             <A HREF="/<?php echo $ADMIN; ?>/articles/autopublish.php?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_article_number=<?php p($articleObj->getArticleNumber()); ?>&f_language_id=<?php  p($f_language_id);?>&f_language_selected=<?php p($articleObj->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/<?php p((count($events) > 0) ? 'automatic_publishing_active.png':'automatic_publishing.png'); ?>" alt="<?php  putGS("Scheduled Publishing"); ?>" title="<?php  putGS("Scheduled Publishing"); ?>" border="0" width="22" height="22"></A>  
    292 402             <?php  
    293 403             } else { ?>  
     
    299 409         </TD>  
    300 410         <?php } ?>  
    301           <TD ALIGN="CENTER">  
    302               <A HREF="" ONCLICK="window.open('/<?php echo $ADMIN; ?>/articles/preview.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($articleObj->getArticleId()); ?>&Language=<?php p($articleObj->getLanguageId()); ?>&sLanguage=<?php  p($articleObj->getLanguageId()); ?>', 'fpreview', 'resizable=yes, menubar=no, toolbar=yes, width=800, height=600'); return false"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/preview.png" alt="<?php  putGS("Preview"); ?>" title="<?php putGS('Preview'); ?>" border="0" width="22" height="22"></A>  
    303           </TD>  
    304    
    305           <?php  if ($User->hasPermission('AddArticle')) { ?>  
    306           <TD ALIGN="CENTER">  
    307               <?php  if ($articleObj->getArticleId() != $previousArticleId) { ?>  
    308               <A HREF="/<?php echo $ADMIN; ?>/articles/translate.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php p($articleObj->getArticleId()); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php p($articleObj->getLanguageId()); ?>&Back=<?php p(urlencode($_SERVER['REQUEST_URI'])); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/translate.png" alt="<?php  putGS("Translate"); ?>" title="<?php  putGS("Translate"); ?>" border="0" width="22" height="22"></A>  
    309               <?php  } else { ?>  
    310                      
    311               <?php  } ?>  
    312           </TD>  
    313 411          
    314           <TD ALIGN="CENTER">  
    315               <A HREF="/<?php echo $ADMIN; ?>/articles/duplicate.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php p($articleObj->getArticleId()); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($articleObj->getLanguageId()); ?>&Back=<?php p(urlencode($_SERVER['REQUEST_URI'])); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/duplicate.png" alt="<?php  putGS("Duplicate"); ?>" title="<?php  putGS("Duplicate"); ?>" border="0" width="22" height="22"></A>  
    316           </TD>  
    317           <?php  } ?>  
    318    
    319           <?php  if ($User->hasPermission('DeleteArticle')) { ?>  
    320           <TD ALIGN="CENTER">  
    321               <A HREF="/<?php echo $ADMIN; ?>/articles/do_del.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php p($articleObj->getArticleId()); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php p($articleObj->getLanguageId()); ?>&ArtOffs=<?php p($ArticleOffset); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the article $1 ($2)?', '"'.camp_javascriptspecialchars($articleObj->getTitle()).'"', camp_javascriptspecialchars($articleObj->getLanguageName())); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0" ALT="<?php  putGS('Delete'); ?>" title="<?php  putGS('Delete'); ?>" width="16" height="16"></A>  
    322           </TD>  
    323           <?php  }  
    324           if ($articleObj->getArticleId() != $previousArticleId)  
    325               $previousArticleId = $articleObj->getArticleId();  
      412         <TD><?php echo $articleObj->onFrontPage() ? "Yes" : "No"; ?></TD>  
      413         <TD><?php echo $articleObj->onSectionPage() ? "Yes" : "No"; ?></TD>  
      414         <TD><?php echo count(ArticleImage::GetImagesByArticleId($articleObj->getArticleNumber())); ?></TD>  
      415         <TD><?php echo count(ArticleTopic::GetArticleTopics($articleObj->getArticleNumber())); ?></TD>  
      416          
      417         <?php  
      418         if ($articleObj->getArticleNumber() != $previousArticleNumber) {  
      419             $previousArticleNumber = $articleObj->getArticleNumber();  
      420         }  
    326 421         ?>   
    327 422     </TR>  
    329 424 } // foreach  
    330 425 ?>   
      426 </table>  
      427 <table class="table_list" style="padding-top: 5px;">  
      428 <tr>  
      429     <td>  
      430         <b><?php putGS("$1 articles found", $numUniqueArticles); ?></b>  
      431     </td>  
      432 </tr>  
    331 433 <TR>  
    332 434     <TD NOWRAP>  
    333 435         <?php  
    334           if ($ArticleOffset > 0) { ?>  
    335               <B><A HREF="index.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>&ArtOffs=<?php  p(max(0, ($ArticleOffset - $ArticlesPerPage))); ?>"><< <?php  putGS('Previous'); ?></A></B>  
      436         if ($f_article_offset > 0) { ?>  
      437             <B><A HREF="index.php?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_language_id=<?php  p($f_language_id); ?>&f_language_selected=<?php  p($f_language_selected); ?>&f_article_offset=<?php  p(max(0, ($f_article_offset - $ArticlesPerPage))); ?>"><< <?php  putGS('Previous'); ?></A></B>  
    336 438         <?php  }  
    337 439  
    338           if ( ($ArticleOffset + $ArticlesPerPage) < $numUniqueArticles) {  
    339               if ($ArticleOffset > 0) {  
      440         if ( ($f_article_offset + $ArticlesPerPage) < $numUniqueArticles) {  
      441             if ($f_article_offset > 0) {  
    340 442                 ?>|<?php  
    341 443             }  
    342 444             ?>  
    343                <B><A HREF="index.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>&ArtOffs=<?php  p(min( ($numUniqueArticles-1), ($ArticleOffset + $ArticlesPerPage))); ?>"><?php  putGS('Next'); ?> >></A></B>  
      445              <B><A HREF="index.php?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_language_id=<?php  p($f_language_id); ?>&f_language_selected=<?php  p($f_language_selected); ?>&f_article_offset=<?php  p(min( ($numUniqueArticles-1), ($f_article_offset + $ArticlesPerPage))); ?>"><?php  putGS('Next'); ?> >></A></B>  
    343 445         <?php  } ?>  
    344 446     </TD>  
    345       <td colspan="3">  
    346           <?php putGS("$1 articles found", $numUniqueArticles); ?>  
    347       </td>  
    348 447 </TR>  
    349 448 </TABLE>  
      449 </form>  
    350 450 <?php  } else { ?><BLOCKQUOTE>  
    351 451     <LI><?php  putGS('No articles.'); ?></LI>  
  • trunk/campsite/implementation/management/priv/articles/do_add.php

    r4032 r4085  
    68 68  
    69 69 // Create article  
    70   $articleObj =& new Article($Pub, $Issue, $Section, $cLanguage);  
      70 $articleObj =& new Article($cLanguage);  
    70 70 $articleObj->create($cType, $cName);  
    71 71 //$articleObj->setOnSectionPage(($cSectionPage == "on"));  
    77 77  
    78 78 $logtext = getGS('Article $1 added to $2. $3 from $4. $5 of $6',  
    79       $cName, $sectionObj->getSectionId(),  
    80       $sectionObj->getName(), $issueObj->getIssueId(),  
      79     $cName, $sectionObj->getSectionNumber(),  
      80     $sectionObj->getName(), $issueObj->getIssueNumber(),  
    81 81     $issueObj->getName(), $publicationObj->getName());  
    82 82 Log::Message($logtext, $User->getUserName(), 31);  
  • trunk/campsite/implementation/management/priv/articles/duplicate.php

    r4083 r4085  
    12 12 }  
    13 13  
    14   $Pub = Input::Get('Pub', 'int', 0);  
    15   $Issue = Input::Get('Issue', 'int', 0);  
    16   $Section = Input::Get('Section', 'int', 0);  
    17   $Language = Input::Get('Language', 'int', 0);  
    18   $sLanguage = Input::Get('sLanguage', 'int', 0);  
    19   $Article = Input::Get('Article', 'int', 0);  
      14 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
      15 $f_issue_number = Input::Get('f_issue_number', 'int', 0);  
      16 $f_section_number = Input::Get('f_section_number', 'int', 0);  
      17 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      18 $f_language_selected = Input::Get('f_language_selected', 'int', 0);  
      19 $f_article_code = Input::Get('f_article_code', 'array', 0);  
    20 20 $f_destination_publication_id = Input::Get('f_destination_publication_id', 'int', 0, true);  
    21 21 $f_destination_issue_id = Input::Get('f_destination_issue_id', 'int', 0, true);  
    22 22 $f_destination_section_id = Input::Get('f_destination_section_id', 'int', 0, true);  
    23   $f_article_name = Input::Get('f_article_name', 'string', '', true);  
    24   //$BackLink = Input::Get('Back', 'string', "/$ADMIN/articles/index.php", true);  
      23  
      24 // Article names can change from page request to page request.  
      25 // We create a 2-dimensional array of article names indexed by article ID, language ID.  
      26 //  
      27 // The user can choose whether to duplicate articles from page request to page request.  
      28 // We create a 2-dimensional array of boolean values indexed by article ID, language ID.  
      29 $articleNames = array();  
      30 $doCopy = array();  
      31 foreach ($_REQUEST as $key => $value) {  
      32     if (!strncmp($key, "f_article_name_", strlen("f_article_name_"))) {  
      33         $tmpCodeStr = str_replace("f_article_name_", "", $key);  
      34         list($articleId, $languageId) = split("_", $tmpCodeStr);  
      35         $articleNames[$articleId][$languageId] = Input::Get($key, 'string', '', true);  
      36     }  
      37     if (!strncmp($key, "f_do_copy_", strlen("f_do_copy_"))) {  
      38         $tmpCodeStr = str_replace("f_do_copy_", "", $key);  
      39         list($articleId, $languageId) = split("_", $tmpCodeStr);  
      40         $doCopy[$articleId][$languageId] = Input::Get($key, 'string', '', true);  
      41     }  
      42 }  
      43  
      44 // Get all the articles we are copying.  
      45 $articles = array();  
      46 foreach ($f_article_code as $code) {  
      47     list($articleNumber, $languageId) = split("_", $code);  
      48     $tmpArticle =& new Article($languageId, $articleNumber);  
      49     $articles[$articleNumber][$languageId] =& $tmpArticle;  
      50      
      51     // Initialize the article names on initial page request.  
      52     // Initialize the $doCopy array on initial page request.  
      53     if (!isset($articleNames[$articleNumber][$languageId])) {  
      54         $articleNames[$articleNumber][$languageId] = $tmpArticle->getTitle();  
      55         $doCopy[$articleNumber][$languageId] = $languageId;  
      56     }  
      57 }  
      58  
      59 // Fill in article names for translations.  
      60 // The user is automatically given the choice to duplicate translations of articles  
      61 // when they get to this screen.  
      62 foreach ($articles as $languageArray) {  
      63     $tmpArticle = camp_array_peek($languageArray);  
      64     $translations = $tmpArticle->getTranslations();  
      65     foreach ($translations as $article) {  
      66         if (!isset($articleNames[$article->getArticleNumber()][$article->getLanguageId()])) {  
      67             $articleNames[$article->getArticleNumber()][$article->getLanguageId()] = $article->getTitle();  
      68         }  
      69     }  
      70 }  
    25 71  
    26 72 if (!Input::IsValid()) {  
     
    29 75 }  
    30 76  
    31   $publicationObj =& new Publication($Pub);  
      77 $publicationObj =& new Publication($f_publication_id);  
    31 77 if (!$publicationObj->exists()) {  
    32 78     camp_html_display_error(getGS('Publication does not exist.'));  
     
    35 81 }  
    36 82  
    37   $issueObj =& new Issue($Pub, $Language, $Issue);  
      83 $issueObj =& new Issue($f_publication_id, $f_language_id, $f_issue_number);  
    37 83 if (!$issueObj->exists()) {  
    38 84     camp_html_display_error(getGS('Issue does not exist.'));  
     
    41 87 }  
    42 88  
    43   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
      89 $sectionObj =& new Section($f_publication_id, $f_issue_number, $f_language_id, $f_section_number);  
    43 89 if (!$sectionObj->exists()) {  
    44 90     camp_html_display_error(getGS('Section does not exist.'));  
    47 93 }  
    48 94  
    49   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
    50   if (!$articleObj->exists()) {  
    51       camp_html_display_error(getGS('Article does not exist.'));  
      95 //  
      96 // This section is executed when the user finally hits the "duplicate" button.  
      97 //  
      98 if (isset($_REQUEST["duplicate_button"])) {  
      99     foreach ($doCopy as $articleNumber => $languageArray) {  
      100         $languageArray = array_keys($languageArray);  
      101         echo "<pre>"; print_r($languageArray); echo "</pre>";  
      102          
      103         $tmpLanguageId = camp_array_peek($languageArray);  
      104          
      105         // Error checking  
      106         if (!isset($articles[$articleNumber][$tmpLanguageId])) {  
      107         echo "error $articleNumber:$tmpLanguageId<br>";  
      108             continue;  
      109         }  
      110          
      111         echo "copying $articleNumber:$tmpLanguageId<br>";  
      112         // Grab the first article - it doesnt matter which one.  
      113         $tmpArticle = $articles[$articleNumber][$tmpLanguageId];  
      114          
      115         // Copy all the translations requested.  
      116         $tmpArticle->copy($f_destination_publication_id,  
      117                           $f_destination_issue_id,  
      118                           $f_destination_section_id,  
      119                           $User->getId(),  
      120                           $languageArray);  
      121     }  
      122     //header("Location:");  
    52 123     exit;  
    53 124 }  
    54 125  
    55   $languageObj =& new Language($Language);  
    56   $sLanguageObj =& new Language($sLanguage);  
    57    
    58 126 $allPublications = Publication::GetPublications();  
    59 127 $allIssues = array();  
    60 128 if ($f_destination_publication_id > 0) {  
    61       $allIssues = Issue::GetIssues($f_destination_publication_id, $Language);  
      129     $allIssues = Issue::GetIssues($f_destination_publication_id, $f_language_id);  
    61 129 }  
    62 130 $allSections = array();  
    63 131 if ($f_destination_issue_id > 0) {  
    64       $allSections = Section::GetSections($f_destination_publication_id, $f_destination_issue_id, $Language);  
    65   }  
    66    
    67   if (empty($f_article_name)) {  
    68       $f_article_name = $articleObj->getUniqueName($articleObj->getTitle());  
      132     $allSections = Section::GetSections($f_destination_publication_id, $f_destination_issue_id, $f_language_id);  
    69 133 }  
    70 134  
    71 135 $topArray = array('Pub' => $publicationObj, 'Issue' => $issueObj,  
    72                     'Section' => $sectionObj, 'Article'=>$articleObj);  
    73   camp_html_content_top(getGS("Duplicate article"), $topArray);  
      136                   'Section' => $sectionObj);  
      137 if (count($articles) > 1) {  
      138     $crumbs = array(getGS("Articles") => "/$ADMIN/articles/index.php?f_publication_id=$f_publication_id&f_issue_number=$f_issue_number&f_section_number=$f_section_number&f_language_id=$f_language_id&f_language_selected=$f_language_selected");  
      139     camp_html_content_top(getGS("Copy article"), $topArray, true, false, $crumbs);  
      140 }  
      141 else {  
      142     $topArray['Article'] = camp_array_peek(camp_array_peek($articles));  
      143     camp_html_content_top(getGS("Copy article"), $topArray);  
      144 }  
    74 145 ?>  
    75 146  
    76 147 <P>  
    77   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" class="table_input">  
      148 <div class="page_title">  
      149 <?php putGS("Copy articles"); ?>:  
      150 </div>  
      151  
      152 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6">  
    78 153 <FORM NAME="duplicate" METHOD="POST">  
    79   <input type="hidden" name="Pub" value="<?php p($Pub); ?>">  
    80   <input type="hidden" name="Issue" value="<?php p($Issue); ?>">  
    81   <input type="hidden" name="Section" value="<?php p($Section); ?>">  
    82   <input type="hidden" name="Language" value="<?php p($Language); ?>">  
    83   <input type="hidden" name="Article" value="<?php p($Article); ?>">  
    84   <input type="hidden" name="sLanguage" value="<?php p($sLanguage); ?>">  
    85   <TR>  
    86       <TD ALIGN="RIGHT" ><?php  putGS("Name"); ?>:</TD>  
    87       <TD>  
    88       <INPUT TYPE="TEXT" NAME="f_article_name" SIZE="64" MAXLENGTH="64" VALUE="<?php  p(htmlspecialchars($f_article_name)); ?>" class="input_text">  
    89       </TD>  
    90   </TR>  
    91   <TR>  
    92       <TD ALIGN="RIGHT" ><?php  putGS("Type"); ?>:</TD>  
    93       <TD>  
    94       <B><?php p(htmlspecialchars($articleObj->getType())); ?></B>  
    95       </TD>  
    96   </TR>  
      154 <input type="hidden" name="f_publication_id" value="<?php p($f_publication_id); ?>">  
      155 <input type="hidden" name="f_issue_number" value="<?php p($f_issue_number); ?>">  
      156 <input type="hidden" name="f_section_number" value="<?php p($f_section_number); ?>">  
      157 <input type="hidden" name="f_language_id" value="<?php p($f_language_id); ?>">  
      158 <?php  
      159 foreach ($articles as $languageArray) {  
      160     foreach ($languageArray as $article) {  ?>  
      161 <input type="hidden" name="f_article_code[]" value="<?php p($article->getArticleNumber()."_".$article->getLanguageId()); ?>">  
      162     <?php  
      163     }  
      164 }  
      165 ?>  
      166 <input type="hidden" name="f_language_selected" value="<?php p($f_language_selected); ?>">  
    97 167 <TR>  
    98       <TD ALIGN="RIGHT" ><?php  putGS("Created"); ?>:</TD>  
    99 168     <TD>  
    100       <B><?php p(htmlspecialchars($articleObj->getUploadDate())); ?> <?php  putGS('(yyyy-mm-dd)'); ?></B>  
    101       </TD>  
    102   </TR>  
    103    
    104   <TR>  
    105       <td colspan="2"> </TD>  
    106   </TR>  
    107   <TR>  
    108       <td colspan="2" style="padding-left: 20px; font-size: 12pt; font-weight: bold;"><?php  putGS("Select destination"); ?></TD>  
    109   </TR>  
    110   <TR>  
    111       <TD VALIGN="middle" ALIGN="RIGHT" style="padding-left: 20px;"><?php  putGS('Publication'); ?>: </TD>  
    112       <TD valign="middle" ALIGN="LEFT">  
    113           <?php if (count($allPublications) > 0) { ?>  
    114           <SELECT NAME="f_destination_publication_id" class="input_select" ONCHANGE="if ((this.selectedIndex != 0) && (this.options[this.selectedIndex].value != <?php p($f_destination_publication_id); ?>)) {this.form.submit();}">  
    115           <OPTION VALUE="0"><?php  putGS('---Select publication---'); ?></option>  
      169         <TABLE cellpadding="3">  
      170         <TR class="table_list_header">  
      171             <TD valign="top"><?php putGS("Copy?"); ?></TD>  
      172             <TD valign="top"><?php putGS("Name"); ?></TD>  
      173             <TD valign="top"><?php putGS("Language"); ?></TD>  
      174             <TD valign="top"><?php putGS("Type"); ?></TD>  
      175         </TR>  
      176          
    116 177         <?php  
    117           foreach ($allPublications as $tmpPublication) {  
    118               pcombovar($tmpPublication->getPublicationId(), $f_destination_publication_id, $tmpPublication->getName());  
    119           }  
    120           ?>  
    121           </SELECT>  
    122           <?php  
    123           }  
    124           else {  
      178         $color = 0;  
      179         foreach ($articles as $languageArray) {  
      180             $count = 0;  
      181             $tmpArticle = camp_array_peek($languageArray);  
      182             $translations = $tmpArticle->getTranslations();  
      183             foreach ($translations as $article) {  
    125 184             ?>  
    126               <SELECT class="input_select" DISABLED><OPTION><?php  putGS('No publications'); ?></option></SELECT>  
    127               <?php  
    128           }  
    129           ?>  
    130       </td>  
    131   </tr>  
    132    
    133   <tr>  
    134       <TD VALIGN="middle" ALIGN="RIGHT" style="padding-left: 20px;"><?php  putGS('Issue'); ?>: </TD>  
    135       <TD valign="middle" ALIGN="LEFT">  
    136           <?php if (($f_destination_publication_id > 0) && (count($allIssues) > 0)) { ?>  
    137           <SELECT NAME="f_destination_issue_id" class="input_select" ONCHANGE="if ((this.selectedIndex != 0) && (this.options[this.selectedIndex].value != <?php p($f_destination_issue_id); ?>)) { this.form.submit(); }">  
    138           <OPTION VALUE="0"><?php  putGS('---Select issue---'); ?></option>  
      185         <TR class="<?php if ($color) { ?>list_row_even<?php } else { ?>list_row_odd<?php } $color = !$color; ?>">  
      186             <TD>  
      187                 <input type="checkbox" name="f_do_copy_<?php p($article->getArticleNumber()."_".$article->getLanguageId()); ?>" value="" <?php if (isset($doCopy[$article->getArticleNumber()][$article->getLanguageId()])) { ?>CHECKED<?php } ?>>  
      188             </TD>  
      189             <TD <?php if ($count++ > 0) { ?>class="translation_indent"<?php } ?>>  
      190                 <INPUT TYPE="TEXT" NAME="f_article_name_<?php p($article->getArticleNumber()."_".$article->getLanguageId()); ?>" SIZE="50" MAXLENGTH="256" VALUE="<?php  p(htmlspecialchars($articleNames[$article->getArticleNumber()][$article->getLanguageId()])); ?>" class="input_text">  
      191             </TD>  
      192              
      193             <TD>  
      194                 <B><?php p(htmlspecialchars($article->getLanguageName())); ?></B>  
      195             </TD>  
      196              
      197             <TD>  
      198                 <B><?php p(htmlspecialchars($article->getType())); ?></B>  
      199             </TD>  
      200              
      201         </TR>  
    139 202         <?php  
    140           foreach ($allIssues as $tmpIssue) {  
    141               pcombovar($tmpIssue->getIssueId(), $f_destination_issue_id, $tmpIssue->getName());  
    142           }  
    143           ?>  
    144           </SELECT>  
    145           <?php   
    146           }  
    147           else {  
    148               ?><SELECT class="input_select" DISABLED><OPTION><?php  putGS('No issues'); ?></SELECT>  
    149               <?php   
      203             }  
    150 204         }  
    151 205         ?>  
    152       </td>  
    153   </tr>  
    154    
    155   <tr>     
    156       <TD VALIGN="middle" ALIGN="RIGHT" style="padding-left: 20px;"><?php  putGS('Section'); ?>: </TD>  
    157       <TD valign="middle" ALIGN="LEFT">  
    158           <?php if (($f_destination_issue_id > 0) && (count($allSections) > 0)) { ?>  
    159           <SELECT NAME="f_destination_section_id" class="input_select" ONCHANGE="if ((this.selectedIndex != 0) && (this.options[this.selectedIndex].value != <?php p($f_destination_section_id); ?>)) { this.form.submit(); }">  
    160           <OPTION VALUE="0"><?php  putGS('---Select section---'); ?>  
    161           <?php  
    162           foreach ($allSections as $tmpSection) {  
    163               pcomboVar($tmpSection->getSectionId(), $f_destination_section_id, $tmpSection->getName());  
    164           }  
    165           ?>  
    166           </SELECT>  
    167           <?php   
    168           }  
    169           else {  
    170               ?><SELECT class="input_select" DISABLED><OPTION><?php  putGS('No sections'); ?></SELECT>  
    171               <?php   
    172           }  
    173           ?>  
    174           </TD>  
    175   </tr>  
    176    
    177   <tr>  
    178       <td colspan="2"><?php  
    179           if ( ($Pub == $f_destination_publication_id) && ($Issue == $f_destination_issue_id) && ($Section == $f_destination_section_id)) {  
    180               putGS("The destination section is the same as the source section."); echo "<BR>\n";  
    181           }  
    182       ?></td>  
    183   </tr>  
      206         </TABLE>  
      207     </TD>  
      208 </TR>  
      209 </TABLE>  
    184 210  
    185   <tr>  
    186       <td align="center" colspan="2">  
    187           <INPUT TYPE="button" Name="Duplicate" Value="<?php putGS("Duplicate article"); ?>" <?php if (($f_destination_publication_id <= 0) || ($f_destination_issue_id <=0) || ($f_destination_section_id <= 0)) { echo 'class="button_disabled"'; } else { echo "class=\"button\" onclick=\"\""; }?> >  
    188       </td>  
    189   </tr>  
      211 <div class="page_title">  
      212 <?php putGS("to section"); ?>:  
      213 </div>  
      214 <p>  
      215 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" class="table_input">  
      216 <TR>  
      217     <TD>  
      218         <TABLE>  
      219         <TR>  
      220             <td colspan="2" style="padding-left: 20px; padding-bottom: 5px;font-size: 12pt; font-weight: bold;"><?php  putGS("Select destination"); ?></TD>  
      221         </TR>  
      222         <TR>  
      223             <TD VALIGN="middle" ALIGN="RIGHT" style="padding-left: 20px;"><?php  putGS('Publication'); ?>: </TD>  
      224             <TD valign="middle" ALIGN="LEFT">  
      225                 <?php if (count($allPublications) > 0) { ?>  
      226                 <SELECT NAME="f_destination_publication_id" class="input_select" ONCHANGE="if ((this.selectedIndex != 0) && (this.options[this.selectedIndex].value != <?php p($f_destination_publication_id); ?>)) {this.form.submit();}">  
      227                 <OPTION VALUE="0"><?php  putGS('---Select publication---'); ?></option>  
      228                 <?php  
      229                 foreach ($allPublications as $tmpPublication) {  
      230                     camp_html_select_option($tmpPublication->getPublicationId(), $f_destination_publication_id, $tmpPublication->getName());  
      231                 }  
      232                 ?>  
      233                 </SELECT>  
      234                 <?php  
      235                 }  
      236                 else {  
      237                     ?>  
      238                     <SELECT class="input_select" DISABLED><OPTION><?php  putGS('No publications'); ?></option></SELECT>  
      239                     <?php  
      240                 }  
      241                 ?>  
      242             </td>  
      243         </tr>  
      244          
      245         <tr>  
      246             <TD VALIGN="middle" ALIGN="RIGHT" style="padding-left: 20px;"><?php  putGS('Issue'); ?>: </TD>  
      247             <TD valign="middle" ALIGN="LEFT">  
      248                 <?php if (($f_destination_publication_id > 0) && (count($allIssues) > 0)) { ?>  
      249                 <SELECT NAME="f_destination_issue_id" class="input_select" ONCHANGE="if ((this.selectedIndex != 0) && (this.options[this.selectedIndex].value != <?php p($f_destination_issue_id); ?>)) { this.form.submit(); }">  
      250                 <OPTION VALUE="0"><?php  putGS('---Select issue---'); ?></option>  
      251                 <?php  
      252                 foreach ($allIssues as $tmpIssue) {  
      253                     camp_html_select_option($tmpIssue->getIssueNumber(), $f_destination_issue_id, $tmpIssue->getName());  
      254                 }  
      255                 ?>  
      256                 </SELECT>  
      257                 <?php   
      258                 }  
      259                 else {  
      260                     ?><SELECT class="input_select" DISABLED><OPTION><?php  putGS('No issues'); ?></SELECT>  
      261                     <?php   
      262                 }  
      263                 ?>  
      264             </td>  
      265         </tr>  
      266          
      267         <tr>     
      268             <TD VALIGN="middle" ALIGN="RIGHT" style="padding-left: 20px;"><?php  putGS('Section'); ?>: </TD>  
      269             <TD valign="middle" ALIGN="LEFT">  
      270                 <?php if (($f_destination_issue_id > 0) && (count($allSections) > 0)) { ?>  
      271                 <SELECT NAME="f_destination_section_id" class="input_select" ONCHANGE="if ((this.selectedIndex != 0) && (this.options[this.selectedIndex].value != <?php p($f_destination_section_id); ?>)) { this.form.submit(); }">  
      272                 <OPTION VALUE="0"><?php  putGS('---Select section---'); ?>  
      273                 <?php  
      274                 foreach ($allSections as $tmpSection) {  
      275                     camp_html_select_option($tmpSection->getSectionNumber(), $f_destination_section_id, $tmpSection->getName());  
      276                 }  
      277                 ?>  
      278                 </SELECT>  
      279                 <?php   
      280                 }  
      281                 else {  
      282                     ?><SELECT class="input_select" DISABLED><OPTION><?php  putGS('No sections'); ?></SELECT>  
      283                     <?php   
      284                 }  
      285                 ?>  
      286                 </TD>  
      287         </tr>  
      288          
      289         <tr>  
      290             <td colspan="2"><?php  
      291                 if ( ($f_publication_id == $f_destination_publication_id) && ($f_issue_number == $f_destination_issue_id) && ($f_section_number == $f_destination_section_id)) {  
      292                     putGS("The destination section is the same as the source section."); echo "<BR>\n";  
      293                 }  
      294             ?></td>  
      295         </tr>  
      296          
      297         <tr>  
      298             <td align="center" colspan="2">  
      299                 <INPUT TYPE="submit" Name="duplicate_button" Value="<?php putGS("Copy article"); ?>" <?php if (($f_destination_publication_id <= 0) || ($f_destination_issue_id <=0) || ($f_destination_section_id <= 0)) { echo 'class="button_disabled"'; } else { echo "class=\"button\""; }?> >  
      300             </td>  
      301         </tr>  
      302         </TABLE>  
      303     </TD>  
      304 </TR>  
    190 305 </FORM>  
    191 306 </table>  
  • trunk/campsite/implementation/management/priv/articles/topics/do_add.php

    r3903 r4085  
    50 50 }  
    51 51  
    52   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      52 $articleObj =& new Article($sLanguage, $Article);  
    52 52 if (!$articleObj->exists()) {  
    53 53     camp_html_display_error(getGS('Article does not exist.'));  
  • trunk/campsite/implementation/management/priv/articles/topics/do_del.php

    r3903 r4085  
    49 49 }  
    50 50  
    51   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      51 $articleObj =& new Article($sLanguage, $Article);  
    51 51 if (!$articleObj->exists()) {  
    52 52     camp_html_display_error(getGS('Article does not exist.'));  
  • trunk/campsite/implementation/management/priv/articles/topics/index.php

    r4054 r4085  
    47 47 }  
    48 48  
    49   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      49 $articleObj =& new Article($sLanguage, $Article);  
    49 49 if (!$articleObj->exists()) {  
    50 50     camp_html_display_error(getGS('Article does not exist.'));  
     
    56 56 $sLanguageObj =& new Language($sLanguage);  
    57 57  
    58   $articleTopics =& ArticleTopic::GetArticleTopics($Article);  
      58 $articleTopics = ArticleTopic::GetArticleTopics($Article);  
    58 58 $articleTopicsIds = DbObjectArray::GetColumn($articleTopics, 'Id');  
    59 59  
    78 78 }  
    79 79 else {  
    80       $subtopics =& $viewTopic->getSubtopics(null, /*$sLanguage, */  
      80     $subtopics = $viewTopic->getSubtopics(null, /*$sLanguage, */  
    80 80         array('LIMIT' => array('START' => $TopicOffset, 'MAX_ROWS'=>($TopicsPerPage))));  
    81 81     $totalSubtopics = count($viewTopic->getSubtopics());  
  • trunk/campsite/implementation/management/priv/articles/editor_load_xinha.php

    r3897 r4085  
    15 15       _editor_url = "/javascript/xinha/";  
    16 16       _editor_lang = "<?php p($_REQUEST['TOL_Language']); ?>";  
    17         _campsite_article_id = <?php echo $_REQUEST['Article']; ?>;  
      17       _campsite_article_id = <?php echo $_REQUEST['f_article_number']; ?>;  
    17 17     //]]>  
    18 18 </script>     
  • trunk/campsite/implementation/management/priv/articles/do_unlock.php

    r3903 r4085  
    19 19 }  
    20 20  
    21   $articleObj =& new Article($PublicationId, $IssueId, $SectionId, $ArticleLanguageId, $ArticleId);  
      21 $articleObj =& new Article($ArticleLanguageId, $ArticleId);  
    21 21  
    22 22 // If the user does not have permission to change the article  
    23 23 // or they didnt create the article, give them the boot.  
    24 24 if (!$articleObj->userCanModify($User)) {  
    25       camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users."));  
      25     camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users."));  
    25 25     exit;     
    26 26 }  
  • trunk/campsite/implementation/management/priv/articles/do_translate.php

    r3903 r4085  
    9 9 }  
    10 10  
    11   $Pub = Input::Get('Pub', 'int', 0);  
    12   $Issue = Input::Get('Issue', 'int', 0);  
    13   $Section = Input::Get('Section', 'int', 0);  
    14   $Language = Input::Get('Language', 'int', 0);  
    15   $sLanguage = Input::Get('sLanguage', 'int', 0);  
    16   $Article = Input::Get('Article', 'int', 0);  
    17   $ArticleLanguage = Input::Get('ArticleLanguage', 'int', 0);  
    18   $cName = trim(Input::Get('cName'));  
    19   $cLanguage = Input::Get('cLanguage');  
    20   $cKeywords = Input::Get('cKeywords');  
    21   $BackLink = Input::Get('Back', 'string', "/$ADMIN/articles/", true);  
      11 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      12 $f_article_code = Input::Get('f_article_code', 'string', 0);  
      13 $f_translation_title = trim(Input::Get('f_translation_title'));  
      14 $f_translation_language = Input::Get('f_translation_language');  
      15 list($articleNumber, $languageId) = split("_", $f_article_code);  
    22 16  
    23 17 if (!Input::IsValid()) {  
    24       camp_html_display_error(getGS('Invalid input: $1', Input::GetErrorString()), $BackLink);  
      18     camp_html_display_error(getGS('Invalid input: $1', Input::GetErrorString()));  
    24 18     exit;     
    25 19 }  
    26   $languageObj =& new Language($cLanguage);  
    27   if (!$languageObj->exists()) {  
    28       camp_html_display_error(getGS('You must select a language.'), $BackLink);  
    29       exit;     
    30   }  
    31    
    32   $publicationObj =& new Publication($Pub);  
    33   if (!$publicationObj->exists()) {  
    34       camp_html_display_error(getGS('Publication does not exist.'), $BackLink);  
    35       exit;     
    36   }  
    37    
    38   $issueObj =& new Issue($Pub, $Language, $Issue);  
    39   if (!$issueObj->exists()) {  
    40       camp_html_display_error(getGS('No such issue.'), $BackLink);  
    41       exit;     
    42   }  
    43    
    44   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    45   if (!$sectionObj->exists()) {  
    46       camp_html_display_error(getGS('No such section.'), $BackLink);  
    47       exit;         
    48   }  
    49 20  
    50   $articleObj =& new Article($Pub, $Issue, $Section, $ArticleLanguage, $Article);  
      21 $articleObj =& new Article($languageId, $articleNumber);  
    50 21 if (!$articleObj->exists()) {  
    51       camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
      22     camp_html_display_error(getGS('Article does not exist.'));  
    51 22     exit;  
    52 23 }  
    53 24  
    54 25 if (!$articleObj->userCanModify($User)) {  
    55       $errorStr = getGS('You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users.');  
    56       camp_html_display_error($errorStr, $BackLink);  
      26     $errorStr = getGS('You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users.');  
      27     camp_html_display_error($errorStr);  
    57 28     exit;     
    58 29 }  
    59 30  
    60   $articleCopy =& $articleObj->createTranslation($cLanguage, $User->getId(), $cName);  
      31 $articleCopy =& $articleObj->createTranslation($f_translation_language, $User->getId(), $f_translation_title);  
    60 31  
    61   $logtext = getGS('Article $1 added to $2. $3 from $4. $5 of $6',  
    62       $cName, $sectionObj->getSectionId(), $sectionObj->getName(),  
    63       $issueObj->getIssueId(), $issueObj->getName(), $publicationObj->getName() );  
    64   Log::Message($logtext, $User->getUserName(), 31);  
    65        
    66   header('Location: '.camp_html_article_url($articleCopy, $Language, 'edit.php'));  
      32 header('Location: '.camp_html_article_url($articleCopy, $languageId, 'edit.php'));  
    67 33 exit;  
    68 34 ?>  
  • trunk/campsite/implementation/management/priv/articles/images/do_add.php

    r4054 r4085  
    42 42 }  
    43 43  
    44   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      44 $articleObj =& new Article($sLanguage, $Article);  
    44 44  
    45 45 // If the template ID is in use, dont add the image.  
    72 72 }  
    73 73  
    74   ArticleImage::AddImageToArticle($image->getImageId(), $articleObj->getArticleId(), $ImageTemplateId);  
      74 ArticleImage::AddImageToArticle($image->getImageId(), $articleObj->getArticleNumber(), $ImageTemplateId);  
    74 74  
    75 75 $logtext = getGS('The image $1 has been added.', $attributes['Description']);  
  • trunk/campsite/implementation/management/priv/articles/images/do_link.php

    r3953 r4085  
    28 28 }  
    29 29  
    30   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      30 $articleObj =& new Article($sLanguage, $Article);  
    30 30 if (!$articleObj->exists()) {  
    31 31     camp_html_display_error(getGS('Article does not exist.'));  
    43 43 // or the user created this article and it hasnt been published yet.  
    44 44 if (!$articleObj->userCanModify($User)) {  
    45       camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users."));  
      45     camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users."));  
    45 45     exit;         
    46 46 }  
  • trunk/campsite/implementation/management/priv/articles/images/do_unlink.php

    r3953 r4085  
    30 30 }  
    31 31  
    32   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      32 $articleObj =& new Article($sLanguage, $Article);  
    32 32  
    33 33 // This file can only be accessed if the user has the right to change articles  
    34 34 // or the user created this article and it hasnt been published yet.  
    35 35 if (!$articleObj->userCanModify($User)) {  
    36       camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users."));  
      36     camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users."));  
    36 36     exit;         
    37 37 }  
  • trunk/campsite/implementation/management/priv/articles/images/edit.php

    r4032 r4085  
    28 28 $issueObj =& new Issue($Pub, $Language, $Issue);  
    29 29 $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    30   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      30 $articleObj =& new Article($sLanguage, $Article);  
    30 30 $imageObj =& new Image($ImageId);  
    31 31  
  • trunk/campsite/implementation/management/priv/articles/images/search.php

    r4054 r4085  
    40 40 $issueObj =& new Issue($Pub, $Language, $Issue);  
    41 41 $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    42   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      42 $articleObj =& new Article($sLanguage, $Article);  
    42 42  
    43 43 ///////////////////////////////////////////////////////////////////////  
  • trunk/campsite/implementation/management/priv/articles/images/do_del.php

    r3953 r4085  
    31 31 }  
    32 32  
    33   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      33 $articleObj =& new Article($sLanguage, $Article);  
    33 33  
    34 34 // This file can only be accessed if the user has the right to change articles  
    40 40 }  
    41 41 if (!$access) {  
    42       camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users."));     
      42     camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users."));      
    42 42     exit;         
    43 43 }  
  • trunk/campsite/implementation/management/priv/articles/images/do_edit.php

    r3953 r4085  
    37 37 }  
    38 38  
    39   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      39 $articleObj =& new Article($sLanguage, $Article);  
    39 39 $publicationObj =& new Publication($Pub);  
    40 40 $issueObj =& new Issue($Pub, $Language, $Issue);  
  • trunk/campsite/implementation/management/priv/articles/images/index.php

    r4054 r4085  
    27 27 $issueObj =& new Issue($Pub, $Language, $Issue);  
    28 28 $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    29   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      29 $articleObj =& new Article($sLanguage, $Article);  
    29 29  
    30 30 $topArray = array('Pub' => $publicationObj, 'Issue' => $issueObj,  
     
    52 52         <TR>  
    53 53             <TD><A HREF="add.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD>  
    54               <TD><A HREF="add.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>" ><B><?php  putGS('Add new image'); ?></B></A></TD>  
      54             <TD><A HREF="add.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>" ><B><?php  putGS('Add New Image'); ?></B></A></TD>  
    54 54         </TR>  
    55 55         </TABLE>  
     
    60 60         <TR>  
    61 61             <TD><?php echo camp_html_article_link($articleObj, $Language, "images/search.php"); ?><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></a></TD>  
    62               <TD><?php echo camp_html_article_link($articleObj, $Language, "images/search.php"); ?><B><?php  putGS('Add an existing image'); ?></B></A></TD>  
      62             <TD><?php echo camp_html_article_link($articleObj, $Language, "images/search.php"); ?><B><?php  putGS('Add an Existing Image'); ?></B></A></TD>  
    62 62         </TR>  
    63 63         </TABLE>  
    70 70 <P>  
    71 71 <?php  
    72   $articleImages = ArticleImage::GetImagesByArticleId($articleObj->getArticleId());  
      72 $articleImages = ArticleImage::GetImagesByArticleId($articleObj->getArticleNumber());  
    72 72 if (count($articleImages) <= 0) {  
    73 73     ?>  
  • trunk/campsite/implementation/management/priv/articles/images/add.php

    r4077 r4085  
    28 28 }  
    29 29  
    30   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      30 $articleObj =& new Article($sLanguage, $Article);  
    30 30 $publicationObj =& new Publication($Pub);  
    31 31 $issueObj =& new Issue($Pub, $Language, $Issue);  
     
    41 41 $topArray = array('Pub' => $publicationObj, 'Issue' => $issueObj,  
    42 42                   'Section' => $sectionObj, 'Article'=>$articleObj);  
    43   camp_html_content_top(getGS("Add new image"), $topArray, true, true, $extraCrumbs);  
      43 camp_html_content_top(getGS("Add New Image"), $topArray, true, true, $extraCrumbs);  
    43 43  
    44 44 ?>  
    62 62 <TR>  
    63 63     <TD COLSPAN="2">  
    64           <B><?php  putGS("Add new image"); ?></B>  
      64         <B><?php  putGS("Add New Image"); ?></B>  
    64 64         <HR NOSHADE SIZE="1" COLOR="BLACK">  
    65 65     </TD>  
  • trunk/campsite/implementation/management/priv/articles/preview.php

    r3955 r4085  
    8 8 }  
    9 9  
    10   $Language = Input::Get('Language', 'int', 0);  
    11   $sLanguage = Input::Get('sLanguage', 'int', 0);  
    12   $Pub = Input::Get('Pub', 'int', 0);  
    13   $Issue = Input::Get('Issue', 'int', 0);  
    14   $Section = Input::Get('Section', 'int', 0);  
    15   $Article = Input::Get('Article', 'int', 0);  
    16    
    17   $languageObj = & new Language($Language);  
    18   $publicationObj = & new Publication($Pub);  
    19   $issueObj =& new Issue($Pub, $Language, $Issue);  
    20   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    21   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      10 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      11 $f_language_selected = Input::Get('f_language_selected', 'int', 0);  
      12 $f_publcation_id = Input::Get('f_publication_id', 'int', 0);  
      13 $f_issue_number = Input::Get('f_issue_number', 'int', 0);  
      14 $f_section_number = Input::Get('f_section_number', 'int', 0);  
      15 $f_article_number = Input::Get('f_article_number', 'int', 0);  
      16  
      17 $languageObj = & new Language($f_language_id);  
      18 $publicationObj = & new Publication($f_publication_id);  
      19 $issueObj =& new Issue($f_publication_id, $f_language_id, $f_issue_number);  
      20 $sectionObj =& new Section($f_publication_id, $f_issue_number, $f_language_id, $f_section_number);  
      21 $articleObj =& new Article($f_language_selected, $f_article_number);  
    22 22  
    23 23 $errorStr = "";  
     
    26 26 } else {  
    27 27     $templateId = $sectionObj->getArticleTemplateId();  
    28       if ($templateId == 0)  
      28     if ($templateId == 0) {  
    28 28         $templateId = $issueObj->getArticleTemplateId();  
    29       if ($templateId == 0)  
      29     }  
      30     if ($templateId == 0) {  
    30 31         $errorStr = getGS('This article cannot be previewed. Please make sure it has the article template selected.');  
      32     }  
    31 33 }  
    32 34  
    33   if ($errorStr != "")  
      35 if ($errorStr != "") {  
    33 35     camp_html_display_error($errorStr, null, true);  
      36 }  
    34 37  
    35 38 setcookie("TOL_UserId", $User->getId(), null, "/");  
    46 49 if ($urlType == 1) {  
    47 50     $templateObj = & new Template($templateId);  
    48       $url = "/look/" . $templateObj->getName() . "?IdLanguage=$Language"  
    49           . "&IdPublication=$Pub&NrIssue=$Issue&NrSection=$Section"  
    50           . "&NrArticle=$Article";  
      51     $url = "/look/" . $templateObj->getName() . "?IdLanguage=$f_language_id"  
      52         . "&IdPublication=$f_publication_id&NrIssue=$f_issue_number&NrSection=$f_section_number"  
      53         . "&NrArticle=$f_article_number";  
    51 54 } else {  
    52 55     $url = "/" . $languageObj->getCode() . "/" . $issueObj->getUrlName()  
  • trunk/campsite/implementation/management/priv/articles/autopublish_del.php

    r3903 r4085  
    13 13 }  
    14 14  
    15   $Pub = Input::Get('Pub', 'int', 0);  
    16   $Issue = Input::Get('Issue', 'int', 0);  
    17   $Section = Input::Get('Section', 'int', 0);  
    18   $Language = Input::Get('Language', 'int', 0);  
    19   $sLanguage = Input::Get('sLanguage', 'int', 0);  
    20   $Article = Input::Get('Article', 'int', 0);  
    21   $publishTime = Input::Get('publish_time');  
      15 $f_language_selected = Input::Get('f_language_selected', 'int', 0);  
      16 $f_article_number = Input::Get('f_article_number', 'int', 0);  
      17 $f_action_id = Input::Get('f_action_id', 'int', 0);  
    22 18 $BackLink = Input::Get('Back', 'string', "/$ADMIN/articles/index.php", true);  
    23 19  
     
    27 23 }  
    28 24  
    29   $publicationObj =& new Publication($Pub);  
    30   if (!$publicationObj->exists()) {  
    31       camp_html_display_error(getGS('Publication does not exist.'), $BackLink);  
    32       exit;     
    33   }  
    34    
    35   $issueObj =& new Issue($Pub, $Language, $Issue);  
    36   if (!$issueObj->exists()) {  
    37       camp_html_display_error(getGS('Issue does not exist.'), $BackLink);  
    38       exit;     
    39   }  
    40    
    41   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    42   if (!$sectionObj->exists()) {  
    43       camp_html_display_error(getGS('Section does not exist.'), $BackLink);  
    44       exit;     
    45   }  
    46    
    47   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      25 $articleObj =& new Article($f_language_selected, $f_article_number);  
    48 26 if (!$articleObj->exists()) {  
    49 27     camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
    51 29 }  
    52 30  
    53   $languageObj =& new Language($Language);  
    54   $sLanguageObj =& new Language($sLanguage);  
    55    
    56   $articlePublishObj =& new ArticlePublish($Article, $sLanguage, $publishTime);  
      31 $articlePublishObj =& new ArticlePublish($f_action_id);  
    57 32 if ($articlePublishObj->exists()) {  
    58 33     $articlePublishObj->delete();  
    59 34 }  
    60   $redirect = camp_html_article_url($articleObj, $Language, "autopublish.php", $BackLink);  
      35 $redirect = camp_html_article_url($articleObj, $f_language_selected, "autopublish.php", $BackLink);  
    60 35 header("Location: $redirect");  
    61 36 exit;  
  • trunk/campsite/implementation/management/priv/articles/status.php

    r4032 r4085  
    21 21 }  
    22 22  
    23   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      23 $articleObj =& new Article($sLanguage, $Article);  
    23 23 if (!$articleObj->exists()) {  
    24 24     camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
    35 35 $access = ($User->hasPermission('Publish') || $articleObj->userCanModify($User));  
    36 36 if (!$access) {  
    37       camp_html_display_error(getGS("You do not have the right to change this article status. Once submitted an article can only changed by authorized users."), $BackLink);  
      37     camp_html_display_error(getGS("You do not have the right to change this article status. Once submitted an article can only be changed by authorized users."), $BackLink);  
    37 37     exit;     
    38 38 }  
  • trunk/campsite/implementation/management/priv/articles/edit.php

    r4083 r4085  
    9 9 }  
    10 10  
    11   $Pub = Input::Get('Pub', 'int', 0);  
    12   $Issue = Input::Get('Issue', 'int', 0);  
    13   $Section = Input::Get('Section', 'int', 0);  
    14   $Language = Input::Get('Language', 'int', 0);  
    15   $sLanguage = Input::Get('sLanguage', 'int', 0);  
    16   $Article = Input::Get('Article', 'int', 0);  
      11 $f_publication_id = Input::Get('f_publication_id', 'int', 0);  
      12 $f_issue_number = Input::Get('f_issue_number', 'int', 0);  
      13 $f_section_number = Input::Get('f_section_number', 'int', 0);  
      14 $f_language_id = Input::Get('f_language_id', 'int', 0);  
      15 $f_language_selected = Input::Get('f_language_selected', 'int', 0);  
      16 $f_article_number = Input::Get('f_article_number', 'int', 0);  
    17 17 $Saved = Input::Get('Saved', 'int', 0, true);  
    18 18 $Unlock = Input::Get('Unlock', 'string', false, true);  
     
    26 26  
    27 27 // Fetch article  
    28   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      28 $articleObj =& new Article($f_language_selected, $f_article_number);  
    28 28 if (!$articleObj->exists()) {  
    29 29     $errorStr = getGS('No such article.');  
     
    32 32 $articleData = $articleObj->getArticleData();  
    33 33 $lockUserObj =& new User($articleObj->getLockedByUser());  
    34   $languageObj =& new Language($Language);  
    35   $sLanguageObj =& new Language($sLanguage);  
    36   $publicationObj =& new Publication($Pub);  
    37   $issueObj =& new Issue($Pub, $Language, $Issue);  
    38   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
      34 $languageObj =& new Language($f_language_id);  
      35 $sLanguageObj =& new Language($f_language_selected);  
      36 $publicationObj =& new Publication($f_publication_id);  
      37 $issueObj =& new Issue($f_publication_id, $f_language_id, $f_issue_number);  
      38 $sectionObj =& new Section($f_publication_id, $f_issue_number, $f_language_id, $f_section_number);  
    39 39 $articleTemplate =& new Template($issueObj->getArticleTemplateId());  
    40 40  
     
    105 105 $topArray = array('Pub' => $publicationObj, 'Issue' => $issueObj,  
    106 106                   'Section' => $sectionObj, 'Article'=>$articleObj);  
    107   camp_html_content_top(getGS("Edit article details"), $topArray);  
      107 camp_html_content_top(getGS("Edit article"), $topArray);  
    107 107 editor_load_xinha($dbColumns, $User);  
    108 108  
     
    125 125         </TR>  
    126 126         <TR>  
    127               <TD COLSPAN="2"><BLOCKQUOTE><font color=red><li><?php  putGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users." ); ?></li></font></BLOCKQUOTE></TD>  
      127             <TD COLSPAN="2"><BLOCKQUOTE><font color=red><li><?php  putGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users." ); ?></li></font></BLOCKQUOTE></TD>  
    127 127         </TR>  
    128 128         <TR>  
    129 129             <TD COLSPAN="2">  
    130 130             <DIV ALIGN="CENTER">  
    131               <INPUT TYPE="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" class="button" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Language=<?php  p($Language); ?>&Section=<?php  p($Section); ?>'">  
      131             <INPUT TYPE="button" NAME="OK" VALUE="<?php  putGS('OK'); ?>" class="button" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_language_id=<?php  p($f_language_id); ?>&f_section_number=<?php  p($f_section_number); ?>'">  
    131 131             </DIV>  
    132 132             </TD>  
     
    177 177         <TD COLSPAN="2">  
    178 178         <DIV ALIGN="CENTER">  
    179           <INPUT TYPE="button" NAME="Yes" VALUE="<?php  putGS('Yes'); ?>" class="button" ONCLICK="location.href='<?php echo camp_html_article_url($articleObj, $sLanguage, "do_unlock.php"); ?>'">  
    180           <INPUT TYPE="button" NAME="No" VALUE="<?php  putGS('No'); ?>" class="button" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Language=<?php p($Language); ?>&Section=<?php  p($Section); ?>'">  
      179         <INPUT TYPE="button" NAME="Yes" VALUE="<?php  putGS('Yes'); ?>" class="button" ONCLICK="location.href='<?php echo camp_html_article_url($articleObj, $f_language_selected, "do_unlock.php"); ?>'">  
      180         <INPUT TYPE="button" NAME="No" VALUE="<?php  putGS('No'); ?>" class="button" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_language_id=<?php p($f_language_id); ?>&f_section_number=<?php  p($f_section_number); ?>'">  
    181 181         </DIV>  
    182 182         </TD>  
     
    245 245                 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1">  
    246 246                 <TR>  
    247                       <TD><?php echo camp_html_article_link($articleObj, $Language, "images/"); ?><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/image_archive.png" BORDER="0"></A></TD>  
    248                       <TD><?php echo camp_html_article_link($articleObj, $Language, "images/"); ?><B><?php  putGS("Images"); ?></B></A></TD>  
      247                     <TD><?php echo camp_html_article_link($articleObj, $f_language_id, "images/"); ?><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/image_archive.png" BORDER="0"></A></TD>  
      248                     <TD><?php echo camp_html_article_link($articleObj, $f_language_id, "images/"); ?><B><?php  putGS("Images"); ?></B></A></TD>  
    249 249                 </TR>  
    250 250                 </TABLE>  
     
    278 278         if ($User->hasPermission('Publish')) {  
    279 279             $automaticPublishingActive = (count(ArticlePublish::GetArticleEvents(  
    280                   $articleObj->getArticleId(), $articleObj->getLanguageId())) > 0);  
      280                 $articleObj->getArticleNumber(), $articleObj->getLanguageId())) > 0);  
    280 280             ?>  
    281 281             <TD class="action_link_container">  
     
    297 297                 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1">  
    298 298                 <TR>     
    299                       <TD><A HREF="" ONCLICK="window.open('/<?php echo $ADMIN; ?>/articles/preview.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>', 'fpreview', 'resizable=yes, menubar=no, toolbar=no, width=680, height=560'); return false"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/preview.png" BORDER="0"></A></TD>  
    300                       <TD><A HREF="" ONCLICK="window.open('/<?php echo $ADMIN; ?>/articles/preview.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Article=<?php  p($Article); ?>&Language=<?php  p($Language); ?>&sLanguage=<?php  p($sLanguage); ?>', 'fpreview', 'resizable=yes, menubar=yes, toolbar=yes, width=680, height=560'); return false"><B><?php  putGS("Preview"); ?></B></A></TD>  
      299                     <TD><A HREF="" ONCLICK="window.open('/<?php echo $ADMIN; ?>/articles/preview.php?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_article_number=<?php  p($f_article_number); ?>&f_language_id=<?php  p($f_language_id); ?>&f_language_selected=<?php  p($f_language_selected); ?>', 'fpreview', 'resizable=yes, menubar=no, toolbar=no, width=680, height=560'); return false"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/preview.png" BORDER="0"></A></TD>  
      300                     <TD><A HREF="" ONCLICK="window.open('/<?php echo $ADMIN; ?>/articles/preview.php?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_article_number=<?php  p($f_article_number); ?>&f_language_id=<?php  p($f_language_id); ?>&f_language_selected=<?php  p($f_language_selected); ?>', 'fpreview', 'resizable=yes, menubar=yes, toolbar=yes, width=680, height=560'); return false"><B><?php  putGS("Preview"); ?></B></A></TD>  
    301 301                 </TR>  
    302 302                 </TABLE>  
     
    322 322                     <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1">  
    323 323                     <TR>  
    324                           <TD><a href="/<?php echo $ADMIN; ?>/articles/do_del.php?Pub=<?php p($Pub); ?>&Issue=<?php p($Issue); ?>&Section=<?php p($Section); ?>&Article=<?php p($Article); ?>&Language=<?php p($Language); ?>&sLanguage=<?php p($sLanguage); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the article $1 ($2)?', '"'.camp_javascriptspecialchars($articleObj->getTitle()).'"', camp_javascriptspecialchars($sLanguageObj->getName())); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0"></A></TD>  
    325                           <TD style="padding-left: 6px;"><a href="/<?php echo $ADMIN; ?>/articles/do_del.php?Pub=<?php p($Pub); ?>&Issue=<?php p($Issue); ?>&Section=<?php p($Section); ?>&Article=<?php p($Article); ?>&Language=<?php p($Language); ?>&sLanguage=<?php p($sLanguage); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the article $1 ($2)?', '"'.camp_javascriptspecialchars($articleObj->getTitle()).'"', camp_javascriptspecialchars($sLanguageObj->getName())); ?>');"><B><?php  putGS("Delete"); ?></B></A></TD>  
      324                         <TD><a href="/<?php echo $ADMIN; ?>/articles/do_del.php?f_publication_id=<?php p($f_publication_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_article_number=<?php p($f_article_number); ?>&f_language_id=<?php p($f_language_id); ?>&f_language_selected=<?php p($f_language_selected); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the article $1 ($2)?', '"'.camp_javascriptspecialchars($articleObj->getTitle()).'"', camp_javascriptspecialchars($sLanguageObj->getName())); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0"></A></TD>  
      325                         <TD style="padding-left: 6px;"><a href="/<?php echo $ADMIN; ?>/articles/do_del.php?f_publication_id=<?php p($f_publication_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_article_number=<?php p($f_article_number); ?>&f_language_id=<?php p($f_language_id); ?>&f_language_selected=<?php p($f_language_selected); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the article $1 ($2)?', '"'.camp_javascriptspecialchars($articleObj->getTitle()).'"', camp_javascriptspecialchars($sLanguageObj->getName())); ?>');"><B><?php  putGS("Delete"); ?></B></A></TD>  
    326 326                     </TR>  
    327 327                     </TABLE>  
     
    336 336                     <TR>  
    337 337                         <TD><A HREF="<?php echo camp_html_article_url($articleObj, $languageObj->getLanguageId(), "duplicate.php"); ?>"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/duplicate.png" BORDER="0"></A></TD>  
    338                           <TD><A HREF="<?php echo camp_html_article_url($articleObj, $languageObj->getLanguageId(), "duplicate.php"); ?>"><B><?php  putGS("Duplicate"); ?></B></A></TD>  
      338                         <TD><A HREF="<?php echo camp_html_article_url($articleObj, $languageObj->getLanguageId(), "duplicate.php"); ?>"><B><?php  putGS("Copy"); ?></B></A></TD>  
    338 338                     </TR>  
    339 339                     </TABLE>  
     
    369 369  
    370 370 <FORM NAME="dialog" METHOD="POST" ACTION="do_edit.php">  
    371   <INPUT TYPE="HIDDEN" NAME="Pub" VALUE="<?php  p($Pub); ?>">  
    372   <INPUT TYPE="HIDDEN" NAME="Issue" VALUE="<?php  p($Issue); ?>">  
    373   <INPUT TYPE="HIDDEN" NAME="Section" VALUE="<?php  p($Section); ?>">  
    374   <INPUT TYPE="HIDDEN" NAME="Article" VALUE="<?php  p($Article); ?>">  
    375   <INPUT TYPE="HIDDEN" NAME="Language" VALUE="<?php  p($Language); ?>">  
    376   <INPUT TYPE="HIDDEN" NAME="sLanguage" VALUE="<?php  p($sLanguage); ?>">  
      371 <INPUT TYPE="HIDDEN" NAME="Pub" VALUE="<?php  p($f_publication_id); ?>">  
      372 <INPUT TYPE="HIDDEN" NAME="Issue" VALUE="<?php  p($f_issue_number); ?>">  
      373 <INPUT TYPE="HIDDEN" NAME="Section" VALUE="<?php  p($f_section_number); ?>">  
      374 <INPUT TYPE="HIDDEN" NAME="Article" VALUE="<?php  p($f_article_number); ?>">  
      375 <INPUT TYPE="HIDDEN" NAME="Language" VALUE="<?php  p($f_language_id); ?>">  
      376 <INPUT TYPE="HIDDEN" NAME="sLanguage" VALUE="<?php  p($f_language_selected); ?>">  
    377 377 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" align="center" class="table_input">  
    378 378 <TR>  
     
    381 381         <tr>  
    382 382             <td align="left">  
    383                   <B><?php putGS("Edit article details"); ?></B>  
      383                 <B><?php putGS("Edit article"); ?></B>  
    383 383             </td>  
    384 384             <TD ALIGN="RIGHT">  
    385 385                 <?php  
    386                   $languageUrl = "edit.php?Pub=$Pub&Issue=$Issue&Section=$Section"  
    387                                 ."&Article=$Article&Language=$Language&sLanguage=";  
      386                 $languageUrl = "edit.php?f_publication_id=$f_publication_id&f_issue_number=$f_issue_number&f_section_number=$f_section_number"  
      387                               ."&f_article_number=$f_article_number&f_language_id=$f_language_id&f_language_selected=";  
    388 388                 ?>  
    389 389                 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="3">  
     
    396 396                             $articleLanguages = $articleObj->getLanguages();  
    397 397                             foreach ($articleLanguages as $articleLanguage) {  
    398                                   pcomboVar($articleLanguage->getLanguageId(), $sLanguage, htmlspecialchars($articleLanguage->getName()));  
      398                                 camp_html_select_option($articleLanguage->getLanguageId(), $f_language_selected, htmlspecialchars($articleLanguage->getName()));  
    398 398                             }  
    399 399                         ?></SELECT>  
     
    409 409                 ?>  
    410 410                 <td align="right">  
    411                   <b><a href="/<?php echo $ADMIN; ?>/article_import/index.php?Pub=<?php p($Pub); ?>&Issue=<?php p($Issue); ?>&Section=<?php p($Section); ?>&Article=<?php p($Article); ?>&Language=<?php p($Language); ?>&sLanguage=<?php p($sLanguage); ?>">Import Article</a></b>  
      411                 <b><a href="/<?php echo $ADMIN; ?>/article_import/index.php?f_publication_id=<?php p($f_publication_id); ?>&f_issue_number=<?php p($f_issue_number); ?>&f_section_number=<?php p($f_section_number); ?>&f_article_number=<?php p($f_article_number); ?>&f_language_id=<?php p($f_language_id); ?>&f_language_selected=<?php p($f_language_selected); ?>">Import Article</a></b>  
    411 411                 </td>  
    412 412                 <?php  
     
    559 559                 foreach ($imageMatches[1] as $templateId) {  
    560 560                     // Get the image URL  
    561                       $articleImage =& new ArticleImage($Article, null, $templateId);  
      561                     $articleImage =& new ArticleImage($f_article_number, null, $templateId);  
    561 561                     $image =& new Image($articleImage->getImageId());  
    562 562                     $imageUrl = $image->getImageUrl();  
    600 600         <DIV ALIGN="CENTER">  
    601 601         <INPUT TYPE="submit" NAME="Save" VALUE="<?php  putGS('Save changes'); ?>" class="button">  
    602           <!--<INPUT TYPE="button" NAME="Cancel" VALUE="<?php  putGS('Cancel'); ?>" class="button" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/?Pub=<?php  p($Pub); ?>&Issue=<?php  p($Issue); ?>&Section=<?php  p($Section); ?>&Language=<?php  p($Language); ?>'">-->  
      602         <!--<INPUT TYPE="button" NAME="Cancel" VALUE="<?php  putGS('Cancel'); ?>" class="button" ONCLICK="location.href='/<?php echo $ADMIN; ?>/articles/?f_publication_id=<?php  p($f_publication_id); ?>&f_issue_number=<?php  p($f_issue_number); ?>&f_section_number=<?php  p($f_section_number); ?>&f_language_id=<?php  p($f_language_id); ?>'">-->  
    602 602         </DIV>  
    603 603         </TD>  
  • trunk/campsite/implementation/management/priv/articles/do_del.php

    r3903 r4085  
    1 1 <?php  
    2 2 require_once($_SERVER['DOCUMENT_ROOT']. "/$ADMIN_DIR/articles/article_common.php");  
    3   require_once($_SERVER['DOCUMENT_ROOT']."/classes/Log.php");  
    4 3  
    5 4 // Check permissions  
     
    30 29 }  
    31 30  
    32   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      31 $articleObj =& new Article($sLanguage, $Article);  
    32 31 if (!$articleObj->exists()) {  
    33 32     camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
    38 37 $articleObj->delete();  
    39 38  
    40   $publicationObj =& new Publication($Pub);  
    41   $issueObj =& new Issue($Pub, $Language, $Issue);  
    42   $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    43   $languageObj =& new Language($Language);  
    44   $sLanguageObj =& new Language($sLanguage);  
    45    
    46   $logtext = getGS('Article $1 ($2) deleted from $3. $4 from $5. $6 ($7) of $8',  
    47       $articleObj->getTitle(), $sLanguageObj->getName(),  
    48       $sectionObj->getSectionId(), $sectionObj->getName(),  
    49       $issueObj->getIssueId(), $issueObj->getName(),  
    50       $languageObj->getName(), $publicationObj->getName() );  
    51   Log::Message($logtext, $User->getUserName(), 32);  
    52    
    53 39 ## added by sebastian  
    54 40 if (function_exists ("incModFile")) {  
  • trunk/campsite/implementation/management/priv/articles/do_move.php

    r3903 r4085  
    10 10 }  
    11 11 if (!$User->hasPermission('Publish')) {  
    12       camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only changed by authorized users." ));  
      12     camp_html_display_error(getGS("You do not have the right to change this article.  You may only edit your own articles and once submitted an article can only be changed by authorized users." ));  
    12 12     exit;  
    13 13 }  
    53 53 $languageObj =& new Language($Language);  
    54 54  
    55   $articleObj =& new Article($Pub, $Issue, $Section, $ArticleLanguage, $Article);  
      55 $articleObj =& new Article($ArticleLanguage, $Article);  
    55 55 if (!$articleObj->exists()) {  
    56 56     camp_html_display_error(getGS('Article does not exist.'), $BackLink);  
  • trunk/campsite/implementation/management/priv/issues/add_article.php

    r3955 r4085  
    58 58     <TR <?php if ($color) { $color=0; ?>class="list_row_even"<?php  } else { $color=1; ?>class="list_row_odd"<?php  } ?>>  
    59 59         <TD ALIGN="RIGHT" >  
    60               <?php p($issue->getIssueId()); ?>  
      60             <?php p($issue->getIssueNumber()); ?>  
    60 60         </TD>  
    61 61          
    62           <TD <?php if ($previousIssueId == $issue->getIssueId()) { ?> style="padding-left: 20px;" <?php } ?>>  
    63               <A HREF="/<?php echo $ADMIN; ?>/sections/add_article.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><?php p(htmlspecialchars($issue->getName())); ?></A> (<?php p(htmlspecialchars($issue->getLanguageName())); ?>)  
      62         <TD <?php if ($previousIssueId == $issue->getIssueNumber()) { ?> style="padding-left: 20px;" <?php } ?>>  
      63             <A HREF="/<?php echo $ADMIN; ?>/sections/add_article.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><?php p(htmlspecialchars($issue->getName())); ?></A> (<?php p(htmlspecialchars($issue->getLanguageName())); ?>)  
    64 64         </TD>  
    65 65          
    77 77     </TR>  
    78 78     <?php  
    79       $previousIssueId = $issue->getIssueId();  
      79     $previousIssueId = $issue->getIssueNumber();  
    79 79 }  
    80 80 ?>   
  • trunk/campsite/implementation/management/priv/issues/translate.php

    r4077 r4085  
    31 31 <P>  
    32 32 <FORM NAME="dialog" METHOD="POST" ACTION="do_translate.php" >  
    33   <CENTER>  
    34   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" CLASS="table_input" ALIGN="CENTER">  
      33 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" CLASS="table_input">  
    35 34 <TR>  
    36 35     <TD COLSPAN="2">  
     
    75 74         <SELECT NAME="cLang" class="input_select"><?php  
    76 75         foreach ($unusedLanguages as $tmpLanguage) {  
    77               pcomboVar($tmpLanguage->getLanguageId(),'',htmlspecialchars($tmpLanguage->getNativeName()));  
      76             camp_html_select_option($tmpLanguage->getLanguageId(),'',htmlspecialchars($tmpLanguage->getNativeName()));  
    77 76         }  
    78 77         ?>  
    92 91         </TD>  
    93 92     </TR>  
    94   </TABLE></CENTER>  
      93 </TABLE>  
    94 93 </FORM>  
    95 94 <P>  
  • trunk/campsite/implementation/management/priv/issues/add_new.php

    r4054 r4085  
    47 47        <?php  
    48 48             foreach ($allLanguages as $language) {  
    49                   pcomboVar($language->getLanguageId(), $publicationObj->getLanguageId(), $language->getNativeName());  
      49                 camp_html_select_option($language->getLanguageId(), $publicationObj->getLanguageId(), $language->getNativeName());  
    49 49             }  
    50 50         ?>  
  • trunk/campsite/implementation/management/priv/issues/do_status.php

    r3955 r4085  
    28 28 $issueObj->setPublished();  
    29 29  
    30   $logtext = getGS('Issue $1 Published: $2  changed status',$issueObj->getIssueId().'. '.$issueObj->getName().' ('.$issueObj->getLanguageName().')',$issueObj->getPublished());  
      30 $logtext = getGS('Issue $1 Published: $2  changed status',$issueObj->getIssueNumber().'. '.$issueObj->getName().' ('.$issueObj->getLanguageName().')',$issueObj->getPublished());  
    30 30 Log::Message($logtext, $User->getUserName(), 14);  
    31 31  
  • trunk/campsite/implementation/management/priv/issues/do_add_prev.php

    r4054 r4085  
    37 37     $issueCopy = array_pop($issueCopies);  
    38 38     $logtext = getGS('New issue $1 from $2 in publication $3', $cNumber,  
    39                        $lastIssue->getIssueId(), $publicationObj->getName());  
      39                      $lastIssue->getIssueNumber(), $publicationObj->getName());  
    39 39     Log::Message($logtext, $User->getUserName(), 11);  
    40       header("Location: /$ADMIN/issues/edit.php?Pub=$Pub&Issue=".$issueCopy->getIssueId()  
      40     header("Location: /$ADMIN/issues/edit.php?Pub=$Pub&Issue=".$issueCopy->getIssueNumber()  
    40 40            ."&Language=".$issueCopy->getLanguageId());  
    41 41     exit;  
  • trunk/campsite/implementation/management/priv/issues/index.php

    r4067 r4085  
    58 58         <TD ALIGN="LEFT" VALIGN="TOP"  ><B><?php  putGS("URL Name"); ?></B></TD>  
    59 59         <TD ALIGN="LEFT" VALIGN="TOP"><B><?php  putGS("Published<BR><SMALL>(yyyy-mm-dd)</SMALL>"); ?></B></TD>  
      60         <TD ALIGN="LEFT" VALIGN="TOP"><B><?php  putGS("Configure"); ?></B></TD>  
    60 61     <?php if ($User->hasPermission('Publish')) { ?>  
    61 62         <TD ALIGN="center" VALIGN="TOP"><B><?php echo str_replace(' ', '<br>', getGS("Scheduled Publishing")); ?></B></TD>  
    62 63     <?php } ?>  
    63 64         <TD ALIGN="LEFT" VALIGN="TOP"><B><?php  putGS("Translate"); ?></B></TD>  
    64           <TD ALIGN="LEFT" VALIGN="TOP"><B><?php  putGS("Configure"); ?></B></TD>  
    65 65         <TD ALIGN="LEFT" VALIGN="TOP"><B><?php  putGS("Preview"); ?></B></TD>  
    66 66     <?php  } else { ?>  
     
    84 84     <?php  if ($User->hasPermission('ManageIssue')) { ?>  
    85 85     <TD ALIGN="RIGHT">  
    86           <?php p($issue->getIssueId()); ?>  
      86         <?php p($issue->getIssueNumber()); ?>  
    86 86     </TD>  
    87 87      
    88       <TD <?php if ($currentIssue == $issue->getIssueId()) { ?> class="translation_indent" <?php } ?>>  
    89           <A HREF="/<?php echo $ADMIN; ?>/sections/?Pub=<?php  p($Pub); ?>&Issue=<?php  p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><?php p(htmlspecialchars($issue->getName())); ?></A> (<?php p(htmlspecialchars($issue->getLanguageName())); ?>)  
      88     <TD <?php if ($currentIssue == $issue->getIssueNumber()) { ?> class="translation_indent" <?php } ?>>  
      89         <A HREF="/<?php echo $ADMIN; ?>/sections/?Pub=<?php  p($Pub); ?>&Issue=<?php  p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><?php p(htmlspecialchars($issue->getName())); ?></A> (<?php p(htmlspecialchars($issue->getLanguageName())); ?>)  
    90 90     </TD>  
    91 91      
     
    96 96      
    97 97     <TD ALIGN="CENTER">  
    98           <A HREF="/<?php echo $ADMIN; ?>/issues/status.php?Pub=<?php p($Pub); ?>&Issue=<?php  p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><?php  if ($issue->getPublished() == 'Y') { p(htmlspecialchars($issue->getPublicationDate())); } else { print putGS("Publish"); } ?></A>  
      98         <A HREF="/<?php echo $ADMIN; ?>/issues/status.php?Pub=<?php p($Pub); ?>&Issue=<?php  p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><?php  if ($issue->getPublished() == 'Y') { p(htmlspecialchars($issue->getPublicationDate())); } else { print putGS("Publish"); } ?></A>  
    98 98     </TD>  
    99   <?php if ($User->hasPermission('Publish')) { ?>  
    100 99     <TD ALIGN="CENTER">  
    101           <A HREF="/<?php echo $ADMIN; ?>/issues/autopublish.php?Pub=<?php p($Pub); ?>&Issue=<?php p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/automatic_publishing.png" alt="<?php putGS("Scheduled Publishing"); ?>"  title="<?php putGS("Scheduled Publishing"); ?>" border="0"></A>  
      100         <A HREF="/<?php echo $ADMIN; ?>/issues/edit.php?Pub=<?php p($Pub); ?>&Issue=<?php  p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/configure.png" alt="<?php  putGS("Configure"); ?>" title="<?php  putGS("Configure"); ?>"  border="0"></A>  
    101 100     </TD>  
    102   <?php } ?>  
      101 <?php if ($User->hasPermission('Publish')) { ?>  
    102 101     <TD ALIGN="CENTER">  
    103           <A HREF="/<?php echo $ADMIN; ?>/issues/translate.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/translate.png" alt="<?php  putGS("Translate"); ?>" title="<?php  putGS("Translate"); ?>" border="0"></A>  
      102         <A HREF="/<?php echo $ADMIN; ?>/issues/autopublish.php?Pub=<?php p($Pub); ?>&Issue=<?php p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/automatic_publishing.png" alt="<?php putGS("Scheduled Publishing"); ?>"  title="<?php putGS("Scheduled Publishing"); ?>" border="0"></A>  
    103 102     </TD>  
      103 <?php } ?>  
    104 104     <TD ALIGN="CENTER">  
    105           <A HREF="/<?php echo $ADMIN; ?>/issues/edit.php?Pub=<?php p($Pub); ?>&Issue=<?php  p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/configure.png" alt="<?php  putGS("Configure"); ?>" title="<?php  putGS("Configure"); ?>"  border="0"></A>  
      105         <A HREF="/<?php echo $ADMIN; ?>/issues/translate.php?Pub=<?php  p($Pub); ?>&Issue=<?php  p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/translate.png" alt="<?php  putGS("Translate"); ?>" title="<?php  putGS("Translate"); ?>" border="0"></A>  
    105 105     </TD>  
    106 106 <?php  } else { ?>  
    107 107     <TD ALIGN="RIGHT">  
    108           <?php p($issue->getIssueId()); ?>  
      108         <?php p($issue->getIssueNumber()); ?>  
    108 108     </TD>  
    109 109      
    110 110     <TD >  
    111           <A HREF="/<?php echo $ADMIN; ?>/issues/sections/?Pub=<?php p($Pub); ?>&Issue=<?php  p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><?php p(htmlspecialchars($issue->getName())); ?></A>  
      111         <A HREF="/<?php echo $ADMIN; ?>/issues/sections/?Pub=<?php p($Pub); ?>&Issue=<?php  p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>"><?php p(htmlspecialchars($issue->getName())); ?></A>  
    111 111     </TD>  
    112 112      
     
    135 135  
    136 136     <TD ALIGN="CENTER">  
    137           <A HREF="" ONCLICK="window.open('/<?php echo $ADMIN; ?>/issues/preview.php?Pub=<?php  p($Pub); ?>&Issue=<?php p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>', 'fpreview', 'resizable=yes, menubar=no, toolbar=yes, width=800, height=600'); return false"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/preview.png" alt="<?php  putGS("Preview"); ?>" title="<?php  putGS("Preview"); ?>" border="0"></A>  
      137         <A HREF="" ONCLICK="window.open('/<?php echo $ADMIN; ?>/issues/preview.php?Pub=<?php  p($Pub); ?>&Issue=<?php p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>', 'fpreview', 'resizable=yes, menubar=no, toolbar=yes, width=800, height=600'); return false"><img src="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/preview.png" alt="<?php  putGS("Preview"); ?>" title="<?php  putGS("Preview"); ?>" border="0"></A>  
    137 137     </TD>  
    138 138  
     
    141 141     if ($User->hasPermission('DeleteIssue')) { ?>  
    142 142         <TD ALIGN="CENTER">  
    143               <A HREF="/<?php echo $ADMIN; ?>/issues/do_del.php?Pub=<?php p($Pub); ?>&Issue=<?php  p($issue->getIssueId()); ?>&Language=<?php p($issue->getLanguageId()); ?>&IssOffs=<?php echo $IssOffs; ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the issue $1?', htmlspecialchars($issue->getName())); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0" ALT="<?php  putGS('Delete issue $1', htmlspecialchars($issue->getName())); ?>" title="<?php  putGS('Delete issue $1', htmlspecialchars($issue->getName())); ?>"></A>  
      143             <A HREF="/<?php echo $ADMIN; ?>/issues/do_del.php?Pub=<?php p($Pub); ?>&Issue=<?php  p($issue->getIssueNumber()); ?>&Language=<?php p($issue->getLanguageId()); ?>&IssOffs=<?php echo $IssOffs; ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the issue $1?', htmlspecialchars($issue->getName())); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0" ALT="<?php  putGS('Delete issue $1', htmlspecialchars($issue->getName())); ?>" title="<?php  putGS('Delete issue $1', htmlspecialchars($issue->getName())); ?>"></A>  
    143 143         </TD>  
    144 144     <?php  } ?>  
    147 147      
    148 148     <?php  
    149       $currentIssue = $issue->getIssueId();  
      149     $currentIssue = $issue->getIssueNumber();  
    149 149 }  
    150 150 ?>   
  • trunk/campsite/implementation/management/priv/issues/do_translate.php

    r4054 r4085  
    52 52  
    53 53 if ($correct) {  
    54       $newIssue = $issueObj->copy(null, $issueObj->getIssueId(), $cLang);  
      54     $newIssue = $issueObj->copy(null, $issueObj->getIssueNumber(), $cLang);  
    54 54     $newIssue->setName($cName);  
    55 55     $newIssue->setUrlName($cShortName);  
  • trunk/campsite/implementation/management/priv/issues/status.php

    r3955 r4085  
    48 48     <TD COLSPAN="2">  
    49 49         <BLOCKQUOTE><LI>  
    50           <?php  putGS('Are you sure you want to change the issue $1 status from $2 to $3?','<B>'.$issueObj->getIssueId().'. '.htmlspecialchars($issueObj->getName()).' ('.htmlspecialchars($issueObj->getLanguageName()).')</B>',"<B>$t2</B>","<B>$t3</B>"); ?>  
      50         <?php  putGS('Are you sure you want to change the issue $1 status from $2 to $3?','<B>'.$issueObj->getIssueNumber().'. '.htmlspecialchars($issueObj->getName()).' ('.htmlspecialchars($issueObj->getLanguageName()).')</B>',"<B>$t2</B>","<B>$t3</B>"); ?>  
    50 50         </LI></BLOCKQUOTE>  
    51 51     </TD>  
  • trunk/campsite/implementation/management/priv/issues/add_prev.php

    r4054 r4085  
    44 44 </TR>  
    45 45 <TR>  
    46       <TD COLSPAN="2"><?php  putGS('Copy structure from issue nr $1','<B>'. $lastCreatedIssue->getIssueId().'</B>'); ?></TD>  
      46     <TD COLSPAN="2"><?php  putGS('Copy structure from issue nr $1','<B>'. $lastCreatedIssue->getIssueNumber().'</B>'); ?></TD>  
    46 46 </TR>  
    47 47 <TR>  
    48 48     <TD ALIGN="RIGHT" ><?php  putGS("Issue Number"); ?>:</TD>  
    49 49     <TD>  
    50       <INPUT TYPE="TEXT" class="input_text" NAME="cNumber" VALUE="<?php  print ($lastCreatedIssue->getIssueId() + 1); ?>" SIZE="5" MAXLENGTH="5">  
      50     <INPUT TYPE="TEXT" class="input_text" NAME="cNumber" VALUE="<?php  print ($lastCreatedIssue->getIssueNumber() + 1); ?>" SIZE="5" MAXLENGTH="5">  
    50 50     </TD>  
    51 51 </TR>  
  • trunk/campsite/implementation/management/priv/issues/edit.php

    r4054 r4085  
    29 29 camp_html_content_top(getGS('Change issue details'), array('Pub' => $publicationObj, 'Issue' => $issueObj));  
    30 30  
      31 $url_args1 = "Pub=$Pub";  
      32 $url_args2 = $url_args1."&Issue=$Issue&Language=$Language";  
      33  
      34 if (Issue::GetNumIssues($Pub) <= 0) {  
      35     $url_add = "add_new.php";  
      36 } else {  
      37     $url_add = "qadd.php";  
      38 }  
    31 39 ?>  
      40 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1" class="action_buttons" style="padding-top: 5px;">  
      41 <TR>  
      42     <TD><A HREF="/<?php echo $ADMIN; ?>/sections/?Pub=<?php  p($Pub); ?>&Issue=<?php  p($issueObj->getIssueNumber()); ?>&Language=<?php p($issueObj->getLanguageId()); ?>"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/go_to.png" BORDER="0"></A></TD>  
      43     <TD><A HREF="/<?php echo $ADMIN; ?>/sections/?Pub=<?php  p($Pub); ?>&Issue=<?php  p($issueObj->getIssueNumber()); ?>&Language=<?php p($issueObj->getLanguageId()); ?>"><B><?php  putGS("Go To Sections"); ?></B></A></TD>  
      44 </TR>  
      45 </TABLE>  
      46  
      47 <P>  
      48 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="1" class="action_buttons">  
      49 <TR>  
      50     <TD><A HREF="<?php p($url_add); ?>?<?php p($url_args1); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/add.png" BORDER="0"></A></TD>  
      51     <TD><A HREF="<?php p($url_add); ?>?<?php p($url_args1); ?>" ><B><?php  putGS("Add new issue"); ?></B></A></TD>  
      52      
      53     <TD style="padding-left: 20px;"><A HREF="" ONCLICK="window.open('preview.php?<?php p($url_args2); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/preview.png" BORDER="0"></A></TD>  
      54     <TD><A HREF="" ONCLICK="window.open('preview.php?<?php p($url_args2); ?>');"><B><?php  putGS("Preview"); ?></B></A></TD>  
      55      
      56     <TD style="padding-left: 20px;"><A HREF="autopublish.php?<?php p($url_args2); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/automatic_publishing.png" BORDER="0"></A></TD>  
      57     <TD><A HREF="autopublish.php?<?php p($url_args2); ?>" ><B><?php  putGS("Scheduled Publishing"); ?></B></A></TD>  
      58      
      59     <TD style="padding-left: 20px;"><A HREF="translate.php?<?php p($url_args2); ?>" ><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/translate.png" BORDER="0"></A></TD>  
      60     <TD><A HREF="translate.php?<?php p($url_args2); ?>" ><B><?php  putGS("Translate"); ?></B></A></TD>  
      61      
      62     <TD style="padding-left: 20px;"><A HREF="do_del.php?<?php p($url_args2); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the issue $1?', htmlspecialchars($issueObj->getName())); ?>');"><IMG SRC="<?php echo $Campsite["ADMIN_IMAGE_BASE_URL"]; ?>/delete.png" BORDER="0"></A></TD>  
      63     <TD><A HREF="do_del.php?<?php p($url_args2); ?>" onclick="return confirm('<?php putGS('Are you sure you want to delete the issue $1?', htmlspecialchars($issueObj->getName())); ?>');"><B><?php  putGS("Delete"); ?></B></A></TD>  
      64 </TR>  
      65 </TABLE>  
    32 66  
    33 67 <P>  
     
    36 70 <INPUT TYPE="HIDDEN" NAME="Issue" VALUE="<?php p($Issue); ?>">  
    37 71 <INPUT TYPE="HIDDEN" NAME="Language" VALUE="<?php p($Language); ?>">  
    38   <CENTER>  
    39   <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" CLASS="table_input" ALIGN="CENTER">  
      72 <TABLE BORDER="0" CELLSPACING="0" CELLPADDING="6" CLASS="table_input">  
    40 73 <TR>  
    41 74     <TD COLSPAN="2">  
     
    57 90         <?php  
    58 91         foreach ($allLanguages as $tmpLanguage) {  
    59               pcomboVar($tmpLanguage->getLanguageId(), $issueObj->getLanguageId(), $tmpLanguage->getNativeName());  
      92             camp_html_select_option($tmpLanguage->getLanguageId(), $issueObj->getLanguageId(), $tmpLanguage->getNativeName());  
    59 92         }  
    60 93         ?>  
     
    80 113         <?php  
    81 114         foreach ($allTemplates as $template) {  
    82               pcomboVar($template->getTemplateId(), $issueObj->getIssueTemplateId(), $template->getName());  
      115             camp_html_select_option($template->getTemplateId(), $issueObj->getIssueTemplateId(), $template->getName());  
    82 115         }  
    83 116         ?>       
     
    94 127         <?php  
    95 128         foreach ($allTemplates as $template) {  
    96               pcomboVar($template->getTemplateId(), $issueObj->getSectionTemplateId(), $template->getName());  
    97               }  
      129             camp_html_select_option($template->getTemplateId(), $issueObj->getSectionTemplateId(), $template->getName());  
      130         }  
    98 131         ?>       
    99 132         </SELECT>  
     
    108 141         <?php  
    109 142         foreach ($allTemplates as $template) {  
    110               pcomboVar($template->getTemplateId(), $issueObj->getArticleTemplateId(), $template->getName());  
      143             camp_html_select_option($template->getTemplateId(), $issueObj->getArticleTemplateId(), $template->getName());  
    110 143         }  
    111 144         ?>  
    131 164 </TR>  
    132 165 </TABLE>  
    133   </CENTER>  
    134 166 </FORM>  
    135 167 <P>  
  • trunk/campsite/implementation/management/priv/article_import/CommandProcessor.php

    r3897 r4085  
    55 55             $docBookParser->parseString($docbookXml, true);  
    56 56              
    57               $article =& new Article($publication, $issue, $section, $articleNumber, $language);  
      57             $article =& new Article($articleNumber, $language);  
    57 57             $article->setTitle($docBookParser->getTitle());  
    58 58             $article->setIntro($docBookParser->getIntro());  
  • trunk/campsite/implementation/management/priv/article_import/index.php

    r3897 r4085  
    28 28 }  
    29 29  
    30   $articleObj =& new Article($Pub, $Issue, $Section, $sLanguage, $Article);  
      30 $articleObj =& new Article($sLanguage, $Article);  
    30 30 $sectionObj =& new Section($Pub, $Issue, $Language, $Section);  
    31 31 $issueObj =& new Issue($Pub, $Language, $Issue);  
    85 85  
    86 86     <TD ALIGN="RIGHT" WIDTH="1%" NOWRAP VALIGN="TOP" class="current_location_title"> <?php putGS("Issue"); ?>:</TD>  
    87       <TD VALIGN="TOP" class="current_location_content"><?php echo $issueObj->getIssueId(); ?>. <?php echo htmlspecialchars($issueObj->getName()); ?> (<?php echo htmlspecialchars($issueLanguage->getName()); ?>)</TD>  
      87     <TD VALIGN="TOP" class="current_location_content"><?php echo $issueObj->getIssueNumber(); ?>. <?php echo htmlspecialchars($issueObj->getName()); ?> (<?php echo htmlspecialchars($issueLanguage->getName()); ?>)</TD>  
    87 87  
    88 88     <TD ALIGN="RIGHT" WIDTH="1%" NOWRAP VALIGN="TOP" class="current_location_title"> <?php putGS("Section"); ?>:</TD>  
    89       <TD VALIGN="TOP" class="current_location_content"><?php echo $sectionObj->getSectionId(); ?>. <?php echo htmlspecialchars($sectionObj->getName()); ?></TD>  
      89     <TD VALIGN="TOP" class="current_location_content"><?php echo $sectionObj->getSectionNumber(); ?>. <?php echo htmlspecialchars($sectionObj->getName()); ?></TD>  
    89 89  
    90 90     <TD ALIGN="RIGHT" WIDTH="1%" NOWRAP VALIGN="TOP" class="current_location_title"> <?php putGS("Article"); ?>:</TD>  
  • trunk/campsite/implementation/management/tests/CampsiteTests.php

    r3895 r4085  
    30 30         $articleCopy =& new Article(9000001, 9000002, 9000003, 9000004, $article->getArticleId());  
    31 31         $this->assertEquals(9000001, $articleCopy->getPublicationId());  
    32           $this->assertEquals(9000002, $articleCopy->getIssueId());  
    33           $this->assertEquals(9000003, $articleCopy->getSectionId());  
      32         $this->assertEquals(9000002, $articleCopy->getIssueNumber());  
      33         $this->assertEquals(9000003, $articleCopy->getSectionNumber());  
    34 34         $this->assertEquals(9000004, $articleCopy->getLanguageId());  
    35 35         $this->assertEquals(9000005, $articleCopy->getUserId());  
  • trunk/campsite/implementation/management/javascript/xinha/popups/campsite_internal_link.php

    r3985 r4085  
    227 227         if (($languageId != 0) && ($publicationId != 0)) {  
    228 228             foreach ($issues as $issue) {  
    229                   $options[$issue->getIssueId()] = substr($issue->getName(), 0, $maxSelectLength);  
      229                 $options[$issue->getIssueNumber()] = substr($issue->getName(), 0, $maxSelectLength);  
    229 229             }  
    230 230             $extras = 'id="NrIssue" onchange="this.form.submit()"';  
     
    246 246         if (($languageId != 0) && ($publicationId != 0) && ($issueId != 0)) {  
    247 247             foreach ($sections as $section) {  
    248                   $options[$section->getSectionId()] = substr($section->getName(), 0, $maxSelectLength);  
      248                 $options[$section->getSectionNumber()] = substr($section->getName(), 0, $maxSelectLength);  
    248 248             }  
    249 249             $extras = 'id="NrSection" onchange="this.form.submit()"';  
    265 265         if (($languageId != 0) && ($publicationId != 0) && ($issueId != 0) && ($sectionId != 0)) {  
    266 266             foreach ($articles as $article) {  
    267                   $options[$article->getArticleId()] = substr($article->getTitle(), 0, $maxSelectLength);  
      267                 $options[$article->getArticleNumber()] = substr($article->getTitle(), 0, $maxSelectLength);  
    267 267             }  
    268 268             $extras = 'id="NrArticle"';  
  • trunk/campsite/implementation/management/css/admin_stylesheet.css

    r4067 r4085  
    106 106     padding-top: 0px;  
    107 107     font-size: 12pt;  
      108     padding-left: 10px;  
    108 109 }  
    109 110  
    152 153     border: 1px solid #8baed1;  
    153 154     margin-left: 15px;  
      155     margin-right: 15px;  
      156     padding-right: 5px;  
    154 157 }  
    155 158  
  • trunk/campsite/implementation/management/classes/Section.php

    r4082 r4085  
    42 42      * @param int $p_issueId  
    43 43      * @param int $p_languageId  
    44        * @param int $p_sectionId  
      44      * @param int $p_sectionNumber  
    44 44      */  
    45 45     function Section($p_publicationId = null, $p_issueId = null,  
    46                        $p_languageId = null, $p_sectionId = null)  
      46                      $p_languageId = null, $p_sectionNumber = null)  
    46 46     {  
    47 47         parent::DatabaseObject($this->m_columnNames);  
     
    51 51         $this->m_data['NrIssue'] = $p_issueId;  
    52 52         $this->m_data['IdLanguage'] = $p_languageId;  
    53           $this->m_data['Number'] = $p_sectionId;  
      53         $this->m_data['Number'] = $p_sectionNumber;  
    53 53         if ($this->keyValuesExist()) {  
    54 54             $this->fetch();  
     
    85 85      * @return int  
    86 86      */  
    87       function getIssueId()  
      87     function getIssueNumber()  
    87 87     {  
    88 88         return $this->getProperty('NrIssue');  
    89       } // fn getIssueId  
      89     } // fn getIssueNumber  
    89 89      
    90 90      
     
    103 103      * @return int  
    104 104      */  
    105       function getSectionId()  
      105     function getSectionNumber()  
    105 105     {  
    106 106         return $this->getProperty('Number');  
    107       } // fn getSectionId  
      107     } // fn getSectionNumber  
    107 107  
    108 108      
     
    140 140      * @param string $p_name  
    141 141      */  
    142       function setShortName($p_name)  
      142     function setUrlName($p_name)  
    142 142     {  
    143 143         return $this->setProperty('ShortName', $p_name);  
    144       } // fn setShortName  
      144     } // fn setUrlName  
    144 144      
    145 145      
     
    156 156      
    157 157     /**  
      158      * @param int $p_value  
      159      * @return boolean  
      160      */  
      161     function setArticleTemplateId($p_value)  
      162     {  
      163         return $this->setProperty('ArticleTplId', $p_value);  
      164     } // fn setArticleTemplateId  
      165      
      166      
      167     /**  
    158 168      * @return int  
    159 169      */  
     
    165 175      
    166 176     /**  
      177      * @param int $p_value  
      178      * @return boolean  
      179      */  
      180     function setSectionTemplateId($p_value)  
      181     {  
      182         return $this->setProperty('SectionTplId', $p_value);  
      183     } // fn setSectionTemplateId  
      184      
      185      
      186     /**  
    167 187      * Delete the section, and optionally the articles.  
    168 188      * @param boolean $p_deleteArticles  
    242 262             $copiedArticles = array();  
    243 263             foreach ($srcSectionArticles as $articleObj) {  
    244                   if (!in_array($articleObj->getArticleId(), $copiedArticles)) {  
      264                 if (!in_array($articleObj->getArticleNumber(), $copiedArticles)) {  
    244 264                     $tmpCopiedArticles = $articleObj->copy($p_destPublicationId,  
    245 265                         $p_destIssueId, $p_destSectionId, null, true);  
    246                       $copiedArticles[] = $articleObj->getArticleId();  
      266                     $copiedArticles[] = $articleObj->getArticleNumber();  
    246 266                 }  
    247 267             }  
  • trunk/campsite/implementation/management/classes/ArticleTopic.php

    r4036 r4085  
    36 36      * @return int  
    37 37      */  
    38       function getArticleId()  
      38     function getArticleNumber()  
    38 38     {  
    39 39         return $this->getProperty('NrArticle');  
    40       } // fn getArticleId  
      40     } // fn getArticleNumber  
    40 40  
    41 41      
  • trunk/campsite/implementation/management/classes/Article.php

    r4082 r4085  
    21 21 require_once($g_documentRoot.'/classes/ArticleIndex.php');  
    22 22 require_once($g_documentRoot.'/classes/Language.php');  
      23 require_once($g_documentRoot.'/classes/Log.php');  
    23 24  
    24 25 /**  
     
    30 31      * @var array  
    31 32      */  
    32       var $m_keyColumnNames = array('IdPublication',  
    33                                     'NrIssue',  
    34                                     'NrSection',  
    35                                     'Number',  
      33     var $m_keyColumnNames = array('Number',  
    36 34                                   'IdLanguage');  
    37 35  
     
    91 89      * the database.  
    92 90      *  
    93        * @param int $p_publicationId  
    94        * @param int $p_issueId  
    95        * @param int $p_sectionId  
    96 91      * @param int $p_languageId  
    97        * @param int $p_articleId  
      92      * @param int $p_articleNumber  
    97 92      *      Not required when creating an article.  
    98 93      */  
    99       function Article($p_publicationId = null, $p_issueId = null, $p_sectionId = null,  
    100                        $p_languageId = null, $p_articleId = null)  
      94     function Article($p_languageId = null, $p_articleNumber = null)  
    101 95     {  
    102 96         parent::DatabaseObject($this->m_columnNames);  
    103           $this->m_data['IdPublication'] = $p_publicationId;  
    104           $this->m_data['NrIssue'] = $p_issueId;  
    105           $this->m_data['NrSection'] = $p_sectionId;  
    106 97         $this->m_data['IdLanguage'] = $p_languageId;  
    107           $this->m_data['Number'] = $p_articleId;  
      98         $this->m_data['Number'] = $p_articleNumber;  
    107 98         if ($this->keyValuesExist()) {  
    108 99             $this->fetch();  
     
    202 193      * @param int $p_userId -  
    203 194      *      The user creating the copy.  If null, keep the same user ID as the original.  
    204        * @param boolean $p_copyAllTranslations -  
    205        *     If true, all translations will be copied as well.  
      195      * @param mixed $p_copyTranslations -  
      196      *      If false, only this article will be copied.  
      197      *      If true, all translations will be copied.  
      198      *      If an array is passed, the translations given will be copied.   
      199      *      Any translations that do not exist will be ignored.  
      200      *  
    206 201      * @return Article  
    207        *     If $p_copyAllTranslations is TRUE, return an array of newly created articles.  
    208        *     If $p_copyAllTranslations is FALSE, return the new Article.  
      202      *     If $p_copyTranslations is TRUE or an array, return an array of newly created articles.  
      203      *     If $p_copyTranslations is FALSE, return the new Article.  
    209 204      */  
    210 205     function copy($p_destPublicationId, $p_destIssueId, $p_destSectionId,  
    211                     $p_userId = null, $p_copyAllTranslations = false)  
      206                   $p_userId = null, $p_copyTranslations = false)  
    211 206     {  
    212 207         global $Campsite;  
    213 208         $copyArticles = array();  
    214           if ($p_copyAllTranslations) {  
      209         if ($p_copyTranslations) {  
    214 209             // Get all translations for this article  
    215 210             $copyArticles = Article::GetArticles($this->m_data['IdPublication'],  
     
    220 215                                                   null,  
    221 216                                                   $this->m_data['Number']);  
      217             // Remove any translations that are not requested to be translated.  
      218             if (is_array($p_copyTranslations)) {  
      219                 $tmpArray = array();  
      220                 foreach ($copyArticles as $tmpArticle) {  
      221                     if (in_array($tmpArticle->m_data['IdLanguage'], $p_copyTranslations)) {  
      222                         $tmpArray[] = $tmpArticle;  
      223                     }  
      224                 }  
      225                 $copyArticles = $tmpArray;  
      226             }  
    222 227         }  
    223 228         else {  
     
    225 230         }  
    226 231         $newArticleId = $this->__generateArticleId();  
    227            
      232  
      233         $logtext = '';  
    228 234         $newArticles = array();  
    229 235         foreach ($copyArticles as $copyMe) {  
     
    274 280             ArticleTopic::OnArticleCopy($copyMe->m_data['Number'], $articleCopy->m_data['Number']);  
    275 281             $newArticles[] = $articleCopy;  
      282             $logtext .= getGS('Article #$1 "$2" ($3) copied to Article #$3. ',  
      283                 $copyMe->getArticleNumber(), $copyMe->getName(),  
      284                 $copyMe->getLanguageId(), $articleCopy->getArticleNumber());  
    276 285         }  
    277           if ($p_copyAllTranslations) {  
      286      
      287         Log::Message($logtext, null, 155);  
      288         if ($p_copyTranslations) {  
    278 289             return $newArticles;  
    279 290         }  
     
    363 374          
    364 375         $origArticleData = $this->getArticleData();  
    365           $origArticleData->copyToExistingRecord($articleCopy->getArticleId(), $p_languageId);  
      376         $origArticleData->copyToExistingRecord($articleCopy->getArticleNumber(), $p_languageId);  
      377          
      378         $logtext = getGS('Article #$1 "$2" ($3) translated to "$5" ($4)',  
      379             $this->getArticleNumber(), $this->getTitle(), $this->getLanguageName(),  
      380             $articleCopy->getTitle(), $articleCopy->getLanguageName());  
      381         Log::Message($logtext, null, 31);  
    366 382          
    367 383         return $articleCopy;  
     
    375 391     function delete()  
    376 392     {  
      393         $logtext = getGS('Article #$1: "$2" ($3) deleted.',  
      394             $this->m_data['Number'], $this->m_data['Name'], $this->getLanguageName())  
      395             ." (".getGS("Publication")." ".$this->m_data['IdPublication'].", "  
      396             ." ".getGS("Issue")." ".$this->m_data['NrIssue'].", "  
      397             ." ".getGS("Section")." ".$this->m_data['NrSection'].")";  
      398              
    377 399         // Delete row from article type table.  
    378 400         $articleData =& new ArticleData($this->m_data['Type'],  
     
    390 412              
    391 413             // Delete indexes  
    392               ArticleIndex::OnArticleDelete($this->getPublicationId(), $this->getIssueId(),  
    393                   $this->getSectionId(), $this->getLanguageId(), $this->getArticleId());  
      414             ArticleIndex::OnArticleDelete($this->getPublicationId(), $this->getIssueNumber(),  
      415                 $this->getSectionNumber(), $this->getLanguageId(), $this->getArticleNumber());  
    394 416         }  
    395 417                      
    396 418         // Delete row from Articles table.  
    397           parent::delete();  
      419         $deleted = parent::delete();  
      420          
      421         if ($deleted) {  
      422             Log::Message($logtext, null, 32);  
      423         }  
      424         return $deleted;  
    398 425     } // fn delete  
    399 426      
     
    517 544         $queryStr = 'SELECT * FROM Sections '  
    518 545                     .' WHERE IdPublication='.$this->getPublicationId()  
    519                       .' AND NrIssue='.$this->getIssueId()  
      546                     .' AND NrIssue='.$this->getIssueNumber()  
    519 546                     .' AND IdLanguage='.$this->getLanguageId();  
    520 547         $query = $Campsite['db']->Execute($queryStr);  
     
    523 550             $queryStr = 'SELECT * FROM Sections '  
    524 551                         .' WHERE IdPublication='.$this->getPublicationId()  
    525                           .' AND NrIssue='.$this->getIssueId()  
      552                         .' AND NrIssue='.$this->getIssueNumber()  
    525 552                         .' LIMIT 1';  
    526 553             $query = $Campsite['db']->Execute($queryStr);     
    527 554         }  
    528 555         $row = $query->FetchRow();  
    529           $section =& new Section($this->getPublicationId(), $this->getIssueId(),  
      556         $section =& new Section($this->getPublicationId(), $this->getIssueNumber(),  
    529 556             $this->getLanguageId());  
    530 557         $section->fetch($row);  
     
    686 713      * @return int  
    687 714      */  
    688       function getIssueId()  
      715     function getIssueNumber()  
    688 715     {  
    689 716         return $this->getProperty('NrIssue');  
    690       } // fn getIssueId  
      717     } // fn getIssueNumber  
    690 717      
    691 718      
     
    695 722      * @return int  
    696 723      */  
    697       function getSectionId()  
      724     function getSectionNumber()  
    697 724     {  
    698 725         return $this->getProperty('NrSection');  
    699       } // fn getSectionId  
      726     } // fn getSectionNumber  
    699 726      
    700 727      
     
    713 740      * @return int  
    714 741      */  
    715       function getArticleId()  
      742     function getArticleNumber()  
    715 742     {  
    716 743         return $this->getProperty('Number');  
    717       } // fn getArticleId  
      744     } // fn getArticleNumber  
    717 744      
    718 745      
     
    842 869      
    843 870      
      871     function getPublishedDisplayString($p_value = null)  
      872     {  
      873         if (is_null($p_value)) {  
      874             $p_value = $this->m_data['Published'];  
      875         }  
      876         if ( ($p_value != 'Y') && ($p_value != 'S') && ($p_value != 'N')) {  
      877             return '';  
      878         }  
      879         switch ($p_value) {  
      880         case 'Y':  
      881             return getGS("Published");  
      882         case 'S':  
      883             return getGS("Submitted");  
      884         case 'N':  
      885             return getGS("New");  
      886         }  
      887     } // fn getPublishedDisplayString  
      888      
      889      
    844 890     /**  
    845 891      * Set the published state of the article.   
     
    856 902             return false;  
    857 903         }  
      904         $logtext = getGS('Article #$1: "$2" status changed from $3 to $4.',  
      905             $this->m_data['Number'], $this->m_data['Name'],  
      906             $this->getPublishedDisplayString(), $this->getPublishedDisplayString($p_value))  
      907             ." (".getGS("Publication")." ".$this->m_data['IdPublication'].", "  
      908             ." ".getGS("Issue")." ".$this->m_data['NrIssue'].", "  
      909             ." ".getGS("Section")." ".$this->m_data['NrSection'].")";  
      910  
    858 911         // If the article is being unpublished  
    859 912         if ( ($this->getPublished() == 'Y') && ($p_value != 'Y') ) {  
    860 913             // Delete indexes  
    861               ArticleIndex::OnArticleDelete($this->getPublicationId(), $this->getIssueId(),  
    862                   $this->getSectionId(), $this->getLanguageId(), $this->getArticleId());  
      914             ArticleIndex::OnArticleDelete($this->getPublicationId(), $this->getIssueNumber(),  
      915                 $this->getSectionNumber(), $this->getLanguageId(), $this->getArticleNumber());  
    863 916         }  
    864 917         // If the article is being published  
     
    871 924             $this->unlock();  
    872 925         }  
    873           return parent::setProperty('Published', $p_value);  
      926         $changed = parent::setProperty('Published', $p_value);  
      927         Log::Message($logtext, null, 35);  
      928         return $changed;  
    874 929     } // fn setPublished  
    875 930      
     
    981 1036      * @param string value  
    982 1037      */  
    983       function setShortName($p_value)  
      1038     function setUrlName($p_value)  
    983 1038     {  
    984 1039         return parent::setProperty('ShortName', $p_value);  
    985       } // fn setShortName  
      1040     } // fn setUrlName  
    985 1040      
    986 1041      
     
    1084 1139         $articles = array();  
    1085 1140         while ($row = $query->FetchRow()) {  
    1086               $tmpArticle =& new Article($row['IdPublication'], $row['NrIssue'],  
    1087                   $row['NrSection'], $row['IdLanguage']);  
      1141             $tmpArticle =& new Article();  
    1088 1142             $tmpArticle->fetch($row);  
    1089 1143             $articles[] = $tmpArticle;  
    1118 1172         $articles = array();  
    1119 1173         while ($row = $query->FetchRow()) {  
    1120               $tmpArticle =& new Article($row['IdPublication'], $row['NrIssue'],  
    1121                   $row['NrSection'], $row['IdLanguage']);  
      1174             $tmpArticle =& new Article();  
    1122 1175             $tmpArticle->fetch($row);  
    1123 1176             $articles[] = $tmpArticle;  
  • trunk/campsite/implementation/management/classes/common.php

    r3953 r4085  
    10 10     require_once($_SERVER['DOCUMENT_ROOT'].'/configuration.php');  
    11 11     require_once($_SERVER['DOCUMENT_ROOT']."/$ADMIN_DIR/lib_campsite.php");  
    12       selectLanguageFile('globals');  
    13       selectLanguageFile("$p_currentDir");  
      12     camp_load_language('globals');  
      13     camp_load_language("$p_currentDir");  
    14 14     require_once($_SERVER['DOCUMENT_ROOT']."/$ADMIN_DIR/languages.php");  
    15 15 } // fn load_common_include_files  
  • trunk/campsite/implementation/management/classes/ArticlePublish.php

    r4054 r4085  
    22 22  */  
    23 23 class ArticlePublish extends DatabaseObject {  
    24       var $m_keyColumnNames = array('NrArticle', 'IdLanguage', 'ActionTime');  
      24     var $m_keyColumnNames = array('id');  
    24 24     var $m_dbTableName = 'ArticlePublish';  
    25       var $m_columnNames = array('NrArticle', 'IdLanguage', 'ActionTime',  
    26                                  'Publish', 'FrontPage', 'SectionPage', 'Completed');  
      25     var $m_keyIsAutoIncrement = true;  
      26     var $m_columnNames = array('id',  
      27                                'fk_article_number',  
      28                                'fk_language_id',  
      29                                'time_action',  
      30                                'publish_action',  
      31                                'publish_on_front_page',  
      32                                'publish_on_section_page',  
      33                                'is_completed');  
    27 34      
    28 35     /**  
    29 36      * This table delays an article's publish time to a later date.  
    30 37      *  
    31        * @param int $p_articleId  
    32        * @param int $p_languageId  
    33        * @param string $p_actionTime  
    34        *  
      38      * @param int $p_id  
    35 39      */  
    36       function ArticlePublish($p_articleId = null, $p_languageId = null, $p_actionTime = null)  
      40     function ArticlePublish($p_id = null)  
    36 40     {  
    37 41         parent::DatabaseObject($this->m_columnNames);  
    38           $this->m_data['NrArticle'] = $p_articleId;  
    39           $this->m_data['IdLanguage'] = $p_languageId;  
    40           $this->m_data['ActionTime'] = $p_actionTime;  
      42         $this->m_data['id'] = $p_id;  
    41 43         if ($this->keyValuesExist()) {  
    42 44             $this->fetch();  
     
    46 48     } // constructor  
    47 49      
      50  
      51     /**  
      52      * Get the unique ID that identifies this action.  
      53      * @return int  
      54      */  
      55     function getArticlePublishId()  
      56     {  
      57         return $this->getProperty('id');  
      58     } // fn getArticlePublishId  
      59      
    48 60      
    49 61     /**  
    50        * Return the article ID associated with this action.  
      62      * Return the article number associated with this action.  
    50 62      * @return int  
    51 63      */  
    52       function getArticleId()  
      64     function getArticleNumber()  
      65     {  
      66         return $this->getProperty('fk_article_number');  
      67     } // fn getArticleNumber  
      68      
      69      
      70     /**  
      71      * Set the Article number.  
      72      * @param int $p_value  
      73      * @return boolean  
      74      */  
      75     function setArticleNumber($p_value)  
    53 76     {  
    54           return $this->getProperty('NrArticle');  
    55       } // fn getArticleId  
      77         return $this->setProperty('fk_article_number', $p_value);  
      78     } // fn setArticleNumber  
    56 79      
    57 80      
     
    63 86     function getLanguageId()  
    64 87     {  
    65           return $this->getProperty('IdLanguage');  
      88         return $this->getProperty('fk_language_id');  
    65 88     } // fn getLanguageId  
    66 89      
    67 90      
    68 91     /**  
      92      * Set the language ID.  
      93      * @param int $p_value  
      94      * @return boolean  
      95      */  
      96     function setLanguageId($p_value)  
      97     {  
      98         return $this->setProperty('fk_language_id', $p_value);  
      99     } // fn setLanguageId  
      100      
      101      
      102     /**  
    69 103      * Get the published state to switch to when the "publish time" arrives:  
    70 104      * NULL for no action, 'P' for Publish, or 'U' for Unpublish.  
     
    74 108     function getPublishAction()  
    75 109     {  
    76           return $this->m_data['Publish'];  
      110         return $this->m_data['publish_action'];  
    76 110     } // fn getPublishAction  
    77 111  
     
    87 121         $p_value = strtoupper($p_value);  
    88 122         if ( ($p_value == 'P') || ($p_value == 'U') ) {  
    89               $this->setProperty('Publish', $p_value);  
      123             $this->setProperty('publish_action', $p_value);  
    89 123         }  
    90 124         elseif (is_null($p_value)) {  
    91               $this->setProperty('Publish', 'NULL', true, true);  
      125             $this->setProperty('publish_action', 'NULL', true, true);  
    91 125         }  
    92 126     } // fn setPublishAction  
     
    102 136     function getFrontPageAction()  
    103 137     {  
    104           return $this->m_data['FrontPage'];  
      138         return $this->m_data['publish_on_front_page'];  
    104 138     } // fn getFrontPageAction  
    105 139      
     
    115 149         $p_value = strtoupper($p_value);  
    116 150         if ( ($p_value == 'S') || ($p_value == 'R') ) {  
    117               $this->setProperty('FrontPage', $p_value);  
      151             $this->setProperty('publish_on_front_page', $p_value);  
    117 151         }  
    118 152         elseif (is_null($p_value)) {  
    119               $this->setProperty('FrontPage', 'NULL', true, true);  
      153             $this->setProperty('publish_on_front_page', 'NULL', true, true);  
    119 153         }  
    120 154     } // fn setFrontPageAction  
     
    130 164     function getSectionPageAction()  
    131 165     {  
    132           return $this->m_data['SectionPage'];  
      166         return $this->m_data['publish_on_section_page'];  
    132 166     } // fn getSectionPageAction  
    133 167      
     
    143 177         $p_value = strtoupper($p_value);  
    144 178         if ( ($p_value == 'S') || ($p_value == 'R') ) {  
    145               $this->setProperty('SectionPage', $p_value);  
      179             $this->setProperty('publish_on_section_page', $p_value);  
    145 179         }  
    146 180         elseif (is_null($p_value)) {  
    147               $this->setProperty('SectionPage', 'NULL', true, true);  
      181             $this->setProperty('publish_on_section_page', 'NULL', true, true);  
    147 181         }  
    148 182     } // fn setSectionPageAction  
     
    157 191     function getActionTime()  
    158 192     {  
    159           return $this->m_data['ActionTime'];  
      193         return $this->m_data['time_action'];  
    159 193     } // fn getActionTime  
    160 194      
    161 195      
    162 196     /**  
      197      * Set the time when the action(s) should be taken.  
      198      * The parameter given should be in the form "YYYY-MM-DD HH:MM:SS".  
      199      * @param string $p_value  
      200      * @return boolean  
      201      */  
      202     function setActionTime($p_value)  
      203     {  
      204         return $this->setProperty('time_action', $p_value);  
      205     } // fn setActionTime  
      206      
      207      
      208     /**  
    163 209      * Mark that this action has been completed.  
    164 210      * @return void  
     
    167 213     function setCompleted()  
    168 214     {  
    169           $this->setProperty('Completed', 'Y');  
      215         $this->setProperty('is_completed', 'Y');  
    169 215     } // fn setCompleted  
    170 216      
     
    180 226         $frontPageAction = $this->getFrontPageAction();  
    181 227         $sectionPageAction = $this->getSectionPageAction();  
    182           $article =& new Article(null, null, null, $this->m_data['IdLanguage'], $this->m_data['NrArticle']);  
    183           $article->setKey(array('Number', 'IdLanguage'));  
      228         $article =& new Article($this->m_data['fk_language_id'], $this->m_data['fk_article_number']);  
    184 229         if ($publishAction == 'P') {  
    185 230             $article->setPublished('Y');  
     
    216 261         global $Campsite;  
    217 262         $queryStr = 'SELECT * FROM ArticlePublish '  
    218                       ." WHERE NrArticle=$p_articleId";  
      263                     ." WHERE fk_article_number=$p_articleId";  
    218 263         if (!is_null($p_languageId)) {  
    219               $queryStr .= " AND IdLanguage=$p_languageId ";  
      264             $queryStr .= " AND fk_language_id=$p_languageId ";  
    219 264         }  
    220           $queryStr .= ' ORDER BY ActionTime ASC ';  
      265         $queryStr .= ' ORDER BY time_action ASC ';  
    220 265         $result = DbObjectArray::Create('ArticlePublish', $queryStr);  
    221 266         return $result;  
     
    235 280         $datetime = strftime("%Y-%m-%d %H:%M:00");  
    236 281         $queryStr = "SELECT * FROM ArticlePublish "  
    237                       . " WHERE ActionTime <= '$datetime'"  
    238                       . " AND Completed != 'Y'"  
    239                       . " ORDER BY ActionTime ASC";  
      282                     . " WHERE time_action <= '$datetime'"  
      283                     . " AND is_completed != 'Y'"  
      284                     . " ORDER BY time_action ASC";  
    240 285         $result = DbObjectArray::Create('ArticlePublish', $queryStr);  
    241 286         return $result;  
     
    269 314         $dummyArticle =& new Article();  
    270 315         $columnNames = $dummyArticle->getColumnNames(true);  
    271           $queryStr = "SELECT ActionTime, Publish, FrontPage, SectionPage,"  
      316         $queryStr = "SELECT id, time_action, publish_action, publish_on_front_page, publish_on_section_page,"  
    271 316                     . implode(",", $columnNames). " FROM Articles, ArticlePublish "  
    272                       . " WHERE ActionTime >= '" . $datetime . "'"  
    273                       . " AND Completed != 'Y'"  
    274                       . " AND Articles.Number=ArticlePublish.NrArticle "  
    275                       . " AND Articles.IdLanguage=ArticlePublish.IdLanguage "  
    276                       . " ORDER BY ActionTime DESC"  
      317                     . " WHERE time_action >= '" . $datetime . "'"  
      318                     . " AND is_completed != 'Y'"  
      319                     . " AND Articles.Number=ArticlePublish.fk_article_number "  
      320                     . " AND Articles.IdLanguage=ArticlePublish.fk_language_id "  
      321                     . " ORDER BY time_action DESC"  
    277 322                     . " LIMIT $p_limit";  
    278 323         $rows = $Campsite['db']->GetAll($queryStr);  
    282 327             foreach ($rows as $row) {  
    283 328                 $row["ObjectType"] = "article";  
    284                   $addKeys[$row['ActionTime']] = $row;  
      329                 $addKeys[$row['time_action']] = $row;  
    284 329             }  
    285 330         }  
  • trunk/campsite/implementation/management/classes/ArticleIndex.php

    r3752 r4085  
    38 38      * @return int  
    39 39      */  
    40       function getArticleId()  
      40     function getArticleNumber()  
    40 40     {  
    41 41         return $this->getProperty('NrArticle');  
    42       } // fn getArticleId  
      42     } // fn getArticleNumber  
    42 42  
    43 43      
  • trunk/campsite/implementation/management/classes/IssuePublish.php

    r4054 r4085  
    23 23  */  
    24 24 class IssuePublish extends DatabaseObject {  
    25       var $m_keyColumnNames = array('IdPublication', 'NrIssue', 'IdLanguage', 'ActionTime');  
      25     var $m_keyColumnNames = array('id');  
    25 25     var $m_dbTableName = 'IssuePublish';  
    26       var $m_columnNames = array('IdPublication', 'NrIssue', 'IdLanguage',  
    27                                  'ActionTime', 'Action', 'PublishArticles', 'Completed');  
      26     var $m_keyIsAutoIncrement = true;  
      27     var $m_columnNames = array('id',  
      28                                'fk_publication_id',  
      29                                'fk_issue_id',  
      30                                'fk_language_id',  
      31                                'time_action',  
      32                                'publish_action',  
      33                                'do_publish_articles',  
      34                                'is_completed');  
    28 35      
    29 36     /**  
    30 37      * This table delays an issue's publish time to a later date.  
    31 38      *  
    32        * @param int $p_articleId  
    33        * @param int $p_issueId  
    34        * @param int $p_languageId  
    35        * @param string $p_actionTime  
    36        *  
      39      * @param int $p_id  
    37 40      */  
    38       function IssuePublish($p_publicationId = null, $p_issueId = null,  
    39                             $p_languageId = null, $p_actionTime = null)  
      41     function IssuePublish($p_id = null)  
    40 42     {  
    41 43         parent::DatabaseObject($this->m_columnNames);  
    42           $this->m_data['IdPublication'] = $p_publicationId;  
    43           $this->m_data['NrIssue'] = $p_issueId;  
    44           $this->m_data['IdLanguage'] = $p_languageId;  
    45           $this->m_data['ActionTime'] = $p_actionTime;  
      44         $this->m_data['id'] = $p_id;  
    46 45         if ($this->keyValuesExist()) {  
    47 46             $this->fetch();  
     
    56 55     function getPublicationId()  
    57 56     {  
    58           return $this->m_data['IdPublication'];  
      57         return $this->m_data['fk_publication_id'];  
    58 57     } // fn getPublicationId  
    59 58      
     
    63 62      * @return int  
    64 63      */  
    65       function getIssueId()  
      64     function getIssueNumber()  
    65 64     {  
    66           return $this->m_data['NrIssue'];  
    67       } // fn getIssueId  
      65         return $this->m_data['fk_issue_id'];  
      66     } // fn getIssueNumber  
    68 67      
    69 68      
     
    74 73     function getLanguageId()  
    75 74     {  
    76           return $this->m_data['IdLanguage'];  
      75         return $this->m_data['fk_language_id'];  
    76 75     } // fn getLanguageId  
    77 76      
     
    85 84     function getPublishAction()  
    86 85     {  
    87           return $this->m_data['Action'];  
      86         return $this->m_data['publish_action'];  
    87 86     } // fn getPublishAction  
    88 87  
     
    99 98         $p_value = strtoupper($p_value);  
    100 99         if ( ($p_value == 'P') || ($p_value == 'U') ) {  
    101               $this->setProperty('Action', $p_value);  
      100             $this->setProperty('publish_action', $p_value);  
    101 100         }  
    102 101     } // fn setPublishAction  
     
    111 110     function getPublishArticlesAction()  
    112 111     {  
    113           return $this->m_data['PublishArticles'];  
      112         return $this->m_data['do_publish_articles'];  
    113 112     } // fn getPublishArticlesAction  
    114 113      
     
    125 124         $p_value = strtoupper($p_value);  
    126 125         if ( ($p_value == 'Y') || ($p_value == 'N') ) {  
    127               $this->setProperty('PublishArticles', $p_value);  
      126             $this->setProperty('do_publish_articles', $p_value);  
    127 126         }  
    128 127     } // fn setPublishArticlesAction  
     
    136 135     function getActionTime()  
    137 136     {  
    138           return $this->m_data['ActionTime'];  
      137         return $this->m_data['time_action'];  
    138 137     } // fn getActionTime  
    139 138      
     
    146 145     function setCompleted()  
    147 146     {  
    148           $this->setProperty('Completed', 'Y');  
      147         $this->setProperty('is_completed', 'Y');  
    148 147     } // fn setCompleted  
    149 148      
     
    156 155     function doAction()  
    157 156     {  
    158           $publicationId = $this->m_data['IdPublication'];  
    159           $issueId = $this->m_data['NrIssue'];  
    160           $languageId = $this->m_data['IdLanguage'];  
    161           $publishAction = $this->m_data['Action'];  
    162           $publishArticlesAction = $this->m_data['PublishArticles'];  
      157         $publicationId = $this->m_data['fk_publication_id'];  
      158         $issueId = $this->m_data['fk_issue_id'];  
      159         $languageId = $this->m_data['fk_language_id'];  
      160         $publishAction = $this->m_data['publish_action'];  
      161         $publishArticlesAction = $this->m_data['do_publish_articles'];  
    163 162  
    164 163         $articleState = ($publishAction == 'P') ? 'Y' : 'S';  
     
    189 188         global $Campsite;  
    190 189         $queryStr = "SELECT * FROM IssuePublish "  
    191                       ." WHERE IdPublication = $p_publicationId "  
    192                       ." AND NrIssue = $p_issueId "  
    193                       ." AND IdLanguage = $p_languageId "  
    194                       ." ORDER BY ActionTime ASC";  
      190                     ." WHERE fk_publication_id = $p_publicationId "  
      191                     ." AND fk_issue_id = $p_issueId "  
      192                     ." AND fk_language_id = $p_languageId "  
      193                     ." ORDER BY time_action ASC";  
    195 194         $result = DbObjectArray::Create('IssuePublish', $queryStr);  
    196 195         return $result;  
     
    206 205         $datetime = strftime("%Y-%m-%d %H:%M:00");  
    207 206         $queryStr = "SELECT * FROM IssuePublish "  
    208                      . " WHERE ActionTime <= '$datetime'"  
    209                      . " AND Completed != 'Y'"  
    210                      . " ORDER BY ActionTime ASC";  
      207                    . " WHERE time_action <= '$datetime'"  
      208                    . " AND is_completed != 'Y'"  
      209                    . " ORDER BY time_action ASC";  
    211 210         $result = DbObjectArray::Create('IssuePublish', $queryStr);  
    212 211         return $result;  
     
    240 239         $dummyIssue =& new Issue();  
    241 240         $columnNames = $dummyIssue->getColumnNames(true);  
    242           $queryStr = "SELECT ActionTime, Action, PublishArticles, "  
      241         $queryStr = "SELECT id, time_action, publish_action, do_publish_articles, "  
    242 241                     . implode(",", $columnNames). " FROM Issues, IssuePublish "  
    243                       . " WHERE ActionTime >= '" . $datetime . "'"  
    244                       . " AND Completed != 'Y'"  
    245                       . " AND Issues.IdPublication=IssuePublish.IdPublication"  
    246                       . " AND Issues.Number=IssuePublish.NrIssue"  
    247                       . " AND Issues.IdLanguage=IssuePublish.IdLanguage "  
    248                       . " ORDER BY ActionTime DESC"  
      242                     . " WHERE time_action >= '" . $datetime . "'"  
      243                     . " AND is_completed != 'Y'"  
      244                     . " AND Issues.IdPublication=IssuePublish.fk_publication_id"  
      245                     . " AND Issues.Number=IssuePublish.fk_issue_id"  
      246                     . " AND Issues.IdLanguage=IssuePublish.fk_language_id "  
      247                     . " ORDER BY time_action DESC"  
    249 248                     . " LIMIT $p_limit";  
    250 249         //echo $queryStr."<br>";  
    255 254             foreach ($rows as $row) {  
    256 255                 $row["ObjectType"] = "issue";             
    257                   $addKeys[$row['ActionTime']] = $row;  
      256                 $addKeys[$row['time_action']] = $row;  
    257 256             }  
    258 257         }  
  • trunk/campsite/implementation/management/classes/Log.php

    r4055 r4085  
    9 9  */  
    10 10 class Log extends DatabaseObject {  
    11       var $m_keyColumnNames = array('IdEvent');  
      11     var $m_keyColumnNames = array('fk_event_id');  
    11 11     var $m_keyIsAutoIncrement = false;  
    12 12     var $m_dbTableName = 'Log';  
    13 13     var $m_columnNames = array(  
    14           'TStamp',  
    15           'IdEvent',  
    16           'User',  
    17           'Text');  
      14         'time_created',  
      15         'fk_event_id',  
      16         'fk_user_id',  
      17         'text');  
      18      
    18 19      
    19 20     /**  
     
    28 29      * @return void  
    29 30      */  
    30       function Message($p_text, $p_userName = '', $p_eventId = 0)  
      31     function Message($p_text, $p_userId = null, $p_eventId = 0)  
    30 31     {  
    31 32         global $Campsite;  
    32           $queryStr = "INSERT INTO Log SET TStamp=NOW(), IdEvent=$p_eventId, User='$p_userName', Text='".mysql_real_escape_string($p_text)."'";  
      33         if (is_null($p_userId)) {  
      34             // try to get the user name from the global environment  
      35             if (isset($_REQUEST['TOL_UserId'])) {  
      36                 $p_userId = $_REQUEST['TOL_UserId'];  
      37             }  
      38         }  
      39         $queryStr = "INSERT INTO Log SET "  
      40                     ." time_created=NOW(), "  
      41                     ." fk_event_id=$p_eventId,"  
      42                     ." fk_user_id=$p_userId, "  
      43                     ." text='".mysql_real_escape_string($p_text)."'";  
    33 44         $Campsite['db']->Execute($queryStr);  
    34 45     } // fn Message  
    35 46      
    36        
      47  
      48     /**  
      49      * Get the time the log message was created.  
      50      * @return string  
      51      */  
    37 52     function getTimeStamp()  
    38 53     {  
    39           return $this->getProperty('TStamp');  
      54         return $this->getProperty('time_created');  
    39 54     } // fn getTimeStamp  
    40 55      
    41 56      
    42       function getUserName()  
    43       {  
    44           return $this->getProperty('User');  
    45       } // fn getUserName  
    46        
    47        
      57     /**  
      58      * Return the log message.  
      59      * @return string  
      60      */  
    48 61     function getText()  
    49 62     {  
    50           return $this->getProperty('Text');  
      63         return $this->getProperty('text');  
    50 63     } // fn getText  
    51 64      
    52 65      
      66     /**  
      67      * Get the event ID which cooresponds to an entry in the "Events" table.  
      68      * @return int  
      69      */  
    53 70     function getEventId()  
    54 71     {  
    55           return $this->getProperty('IdEvent');  
      72         return $this->getProperty('fk_event_id');  
    55 72     } // fn getEventId  
    56 73      
    57 74      
      75     /**  
      76      * Return the number of log lines.  
      77      * @param int $p_eventId  
      78      * @return int  
      79      */  
    58 80     function GetNumLogs($p_eventId = null)  
    59 81     {  
     
    65 87         $queryStr = 'SELECT COUNT(*) FROM Log';  
    66 88         if (!is_null($p_eventId)) {  
    67               $queryStr .= " WHERE IdEvent=$p_eventId";  
      89             $queryStr .= " WHERE fk_event_id=$p_eventId";  
    67 89         }  
    68 90         $total = $Campsite['db']->GetOne($queryStr);  
    72 94      
    73 95      
      96     /**  
      97      * Get the logs.  
      98      *  
      99      * @param int $p_eventId  
      100      * @param array $p_sqlOptions  
      101      *  
      102      * @return array  
      103      */  
    74 104     function GetLogs($p_eventId = null, $p_sqlOptions = null)  
    75 105     {  
    76 106         if (is_null($p_sqlOptions) || !isset($p_sqlOptions['ORDER BY'])) {  
    77               $p_sqlOptions['ORDER BY'] = array('TStamp' => 'DESC');  
      107             $p_sqlOptions['ORDER BY'] = array('time_created' => 'DESC');  
    77 107         }  
    78           $constraints = array();  
      108         $tmpLog =& new Log();  
      109         $columns = $tmpLog->getColumnNames(true);  
      110         $queryStr = "SELECT ".implode(", ", $columns)  
      111                     .", Users.Name as full_name, Users.UName as user_name"  
      112                     ." FROM Log, Users"  
      113                     ." WHERE Log.fk_user_id = Users.Id";  
    79 114         if (!is_null($p_eventId)) {  
    80               $constraints[] = array('IdEvent', $p_eventId);  
      115             $queryStr .= " AND Log.fk_event_id=$p_eventId";  
    80 115         }  
    81           return DatabaseObject::Search('Log', $constraints, $p_sqlOptions);  
      116         $queryStr = DatabaseObject::ProcessOptions($queryStr, $p_sqlOptions);  
      117         $logLines = DbObjectArray::Create('Log', $queryStr);  
      118         return $logLines;  
    82 119     } // fn GetLogs  
    83 120      
  • trunk/campsite/implementation/management/classes/ArticleImage.php

    r4054 r4085  
    54 54      * @return int  
    55 55      */  
    56       function getArticleId()  
      56     function getArticleNumber()  
    56 56     {  
    57 57         return $this->getProperty('NrArticle');  
    58       } // fn getArticleId  
      58     } // fn getArticleNumber  
    58 58  
    59 59      
  • trunk/campsite/implementation/management/classes/Issue.php

    r4054 r4085  
    42 42      * @param int $p_publicationId  
    43 43      * @param int $p_languageId  
    44        * @param int $p_issueId  
      44      * @param int $p_issueNumber  
    44 44      */  
    45       function Issue($p_publicationId = null, $p_languageId = null, $p_issueId = null)  
      45     function Issue($p_publicationId = null, $p_languageId = null, $p_issueNumber = null)  
    45 45     {  
    46 46         parent::DatabaseObject($this->m_columnNames);  
    47 47         $this->m_data['IdPublication'] = $p_publicationId;  
    48 48         $this->m_data['IdLanguage'] = $p_languageId;  
    49           $this->m_data['Number'] = $p_issueId;  
      49         $this->m_data['Number'] = $p_issueNumber;  
    49 49         if ($this->keyValuesExist()) {  
    50 50             $this->fetch();  
     
    126 126      * Create a copy of this issue.  You can use this to:  
    127 127      * 1) Translate an issue.  In this case do:  
    128        *    $issue->copy(null, $issue->getIssueId(), $destinationLanguage);  
      128      *    $issue->copy(null, $issue->getIssueNumber(), $destinationLanguage);  
    128 128      * 2) Duplicate all translations of an issue within a publication:  
    129 129      *    $issue->copy();  
    213 213      * @return int  
    214 214      */  
    215       function getIssueId()  
      215     function getIssueNumber()  
    215 215     {  
    216 216         return $this->getProperty('Number');  
    217       } // fn getIssueId  
      217     } // fn getIssueNumber  
    217 217      
    218 218