Startseite
  • » Home
  • » Handbuch & FAQ
  • » Forum
  • » Übersetzungsserver
  • » Suche
Startseite › Forum › Drupalcenter.de › Allgemeines zu Drupal ›

Fehlermeldung: "Ihre Antwort bezieht sich auf einen Kommentar, der nicht vorhanden ist"

Eingetragen von a-c.meiser (69)
am 20.04.2009 - 07:21 Uhr in
  • Allgemeines zu Drupal
  • Drupal 5.x

Hallo zusammen,

ab und an bekomme ich beim Abschicken einer Antwort im Forum die Fehlermeldung "Ihre Antwort bezieht sich auf einen Kommentar, der nicht vorhanden ist". Die Antwort wird trotzdem gespeichert. Ich habe bisher auch keine Regelmäßigkeit oder Ursache für diese Fehlermeldung herausgefunden. Wie ist das zu erklären?

In irgendeinem Thread habe ich gelesen, dass es was mit dem Path Modul zu tun hat. Kann das jemand bestätigen? Und wenn ja, was genau muss ich machen um die Fehlermeldung nicht mehr zu bekommen? Modul aktivieren reicht wohl nicht (das hab ich schon versucht).

‹ Boxen mit unterschiedlichen CSS Aufwand für Einsteigerschulung ›
  • Anmelden oder Registrieren um Kommentare zu schreiben

Hat niemand Erfahrung mit

Eingetragen von a-c.meiser (69)
am 23.04.2009 - 12:39 Uhr

Hat niemand Erfahrung mit dieser Fehlermeldung?

  • Anmelden oder Registrieren um Kommentare zu schreiben

Ich habe vermutlich die

Eingetragen von a-c.meiser (69)
am 14.07.2009 - 14:11 Uhr

Ich habe vermutlich die Stelle gefunden, an der diese Fehlermeldung erzeugt wird:

/**
* This function is responsible for generating a comment reply form.
* There are several cases that have to be handled, including:
*   - replies to comments
*   - replies to nodes
*   - attempts to reply to nodes that can no longer accept comments
*   - respecting access permissions ('access comments', 'post comments', etc.)
*
* The node or comment that is being replied to must appear above the comment
* form to provide the user context while authoring the comment.
*
* @param $nid
*   Every comment belongs to a node. This is that node's id.
* @param $pid
*   Some comments are replies to other comments. In those cases, $pid is the parent
*   comment's cid.
*
* @return $output
*   The rendered parent node or comment plus the new comment form.
*/
function comment_reply($nid, $pid = NULL) {
  // Load the parent node.
  $node = node_load($nid);

  // Set the breadcrumb trail.
  menu_set_location(array(array('path' => "node/$nid", 'title' => $node->title), array('path' => "comment/reply/$nid")));

  $op = isset($_POST['op']) ? $_POST['op'] : '';

  $output = '';

  if (user_access('access comments')) {
    // The user is previewing a comment prior to submitting it.
    if ($op == t('Preview comment')) {
      if (user_access('post comments')) {
        $output .= comment_form_box(array('pid' => $pid, 'nid' => $nid), NULL);
      }
      else {
        drupal_set_message(t('You are not authorized to post comments.'), 'error');
        drupal_goto("node/$nid");
      }
    }
    else {
      // $pid indicates that this is a reply to a comment.
      if ($pid) {
        // load the comment whose cid = $pid
        if ($comment = db_fetch_object(db_query('SELECT c.*, u.uid, u.name AS registered_name, u.picture, u.data FROM {comments} c INNER JOIN {users} u ON c.uid = u.uid WHERE c.cid = %d AND c.status = %d', $pid, COMMENT_PUBLISHED))) {
          // If that comment exists, make sure that the current comment and the parent comment both
          // belong to the same parent node.
          if ($comment->nid != $nid) {
            // Attempting to reply to a comment not belonging to the current nid.
            drupal_set_message(t('The comment you are replying to does not exist.'), 'error');
            drupal_goto("node/$nid");
          }
          // Display the parent comment
          $comment = drupal_unpack($comment);
          $comment->name = $comment->uid ? $comment->registered_name : $comment->name;
          $output .= theme('comment_view', $comment);
        }
        else {
          drupal_set_message(t('The comment you are replying to does not exist.'), 'error');
          drupal_goto("node/$nid");
        }
      }
      // This is the case where the comment is in response to a node. Display the node.
      else if (user_access('access content')) {
        $output .= node_view($node);
      }

      // Should we show the reply box?
      if (node_comment_mode($nid) != COMMENT_NODE_READ_WRITE) {
        drupal_set_message(t("This discussion is closed: you can't post new comments."), 'error');
        drupal_goto("node/$nid");
      }
      else if (user_access('post comments')) {
        $output .= comment_form_box(array('pid' => $pid, 'nid' => $nid), t('Reply'));
      }
      else {
        drupal_set_message(t('You are not authorized to post comments.'), 'error');
        drupal_goto("node/$nid");
      }
    }
  }
  else {
    drupal_set_message(t('You are not authorized to view comments.'), 'error');
    drupal_goto("node/$nid");
  }

  return $output;
}

Den Durchblick hab ich allerdings immer noch nicht. Kann mir jetzt endlich jemand helfen? Ich verstehe nicht wie diese Fehlermeldung auftreten kann, wenn der Beitrag, auf den sich das Kommentar bezieht, vorhanden ist. Außerdem verstehe ich nicht wie es sein kann, dass das "Parent-Comment" und der Beitrag nicht zusammen gehören, wenn man doch in einem Beitrag explizit auf Antworten klickt? Wann kann denn ein solcher Fall passieren?

  • Anmelden oder Registrieren um Kommentare zu schreiben

Benutzeranmeldung

  • Registrieren
  • Neues Passwort anfordern

Aktive Forenthemen

  • für drupal11 ein Slider Modul
  • [gelöst] W3CSS Paragraphs Views
  • Drupal 11 neu aufsetzen und Bereiche aus 10 importieren
  • Wie erlaubt man neuen Benutzern auf die Resetseite zugreifen zu dürfen.
  • [gelöst] Anzeigeformat Text mit Bild in einem Artikel, Drupal 11
  • Social Media Buttons um Insteragram erweitern
  • Nach Installation der neuesten D10-Version kein Zugriff auf Website
  • Composer nach Umzug
  • [gelöst] Taxonomie Begriffe zeigt nicht alle Nodes an
  • Drupal 11 + Experience Builder (Canvas) + Layout Builder
  • Welche KI verwendet ihr?
  • Update Manger läst sich nicht Installieren
Weiter

Neue Kommentare

  • melde mich mal wieder, da ich
    vor 1 Woche 5 Tagen
  • Hey danke
    vor 1 Woche 5 Tagen
  • Update: jetzt gibt's ein
    vor 1 Woche 6 Tagen
  • Hallo, im Prinzip habe ich
    vor 2 Wochen 3 Tagen
  • Da scheint die Terminologie
    vor 2 Wochen 4 Tagen
  • Kannst doch auch alles direkt
    vor 3 Wochen 1 Tag
  • In der entsprechenden View
    vor 3 Wochen 1 Tag
  • Dazu müsstest Du vermutlich
    vor 3 Wochen 1 Tag
  • gelöst
    vor 5 Wochen 4 Tagen
  • Ja natürlich. Dass ist etwas,
    vor 5 Wochen 5 Tagen

Statistik

Beiträge im Forum: 250233
Registrierte User: 20452

Neue User:

  • ByteScrapers
  • Mroppoofpaync
  • 4aficiona2

» Alle User anzeigen

User nach Punkten sortiert:
wla9461
stBorchert6003
quiptime4972
Tobias Bähr4019
bv3924
ronald3857
md3717
Thoor3678
Alexander Langer3416
Exterior2903
» User nach Punkten
Zur Zeit sind 0 User und 4 Gäste online.

Hauptmenü

  • » Home
  • » Handbuch & FAQ
  • » Forum
  • » Übersetzungsserver
  • » Suche

Quicklinks I

  • Infos
  • Drupal Showcase
  • Installation
  • Update
  • Forum
  • Team
  • Verhaltensregeln

Quicklinks II

  • Drupal Jobs
  • FAQ
  • Drupal-Kochbuch
  • Best Practice - Drupal Sites - Guidelines
  • Drupal How To's

Quicklinks III

  • Tipps & Tricks
  • Drupal Theme System
  • Theme Handbuch
  • Leitfaden zur Entwicklung von Modulen

RSS & Twitter

  • Drupal Planet deutsch
  • RSS Feed News
  • RSS Feed Planet
  • Twitter Drupalcenter
Drupalcenter Team | Impressum & Datenschutz | Kontakt
Angetrieben von Drupal | Drupal is a registered trademark of Dries Buytaert.
Drupal Initiative - Drupal Association