Ich versuche, eine benutzerdefinierte Weiterleitung auf Lebensmittelgeschäft Crud auf der Schaltfläche Speichern auf dem Bearbeitungsbildschirm zu verwenden. Ich kann unter Verwendung des URL-Fragments wie das Beispiel erfolgreich umleiten:Grocery Crud URL Umleitung über Javascript
$the_catalogue_id = $this->uri->segment(count($this->uri->segments));
$this->grocery_crud->set_lang_string('update_success_message',
'Your data has been successfully stored into the database.<br/>Please wait while you are redirecting to the list page.
<script type="text/javascript">
window.location = "'.base_url('catalogues/edit').'/'.$the_catalogue_id.'";
</script>
<div style="display:none">'
);
Ich brauche jetzt den window.location.hash bis zum Ende der Umleitungs-URL hinzufügen, aber kann nicht scheinen, um es an der Arbeit. Das ist was ich bisher habe:
$this->grocery_crud->set_lang_string('update_success_message',
'Your data has been successfully stored into the database.<br/>Please wait while you are redirecting to the list page.
<script type="text/javascript">
var thehash = window.location.hash
window.location = "'.base_url('catalogues/edit').'/'.$the_catalogue_id.'"#"+thehash";
</script>
<div style="display:none">'
);
Wie füge ich die Hash-Variable an das Ende der Weiterleitung URL?