drunter ist doch e ein link im Rep zum Manual!
http://typo3.org/documentation/document-library/cwt_community/
Vistenkarten - System
:o
Danke. :p
Also, ich hab jetzt dieses plugin installiert. Und ich habe alles gemacht was da in der Anleitung stand.
Wenn ich die PID öffne (also auf Seite index.php?id="Userlist" usw.) gehe sagt er mir nur "Bitte einloggen". Einen Login habe ich bisher nicht, wie mache ich einen? Und wie legt man einen User an?
zB mit der ext newloginbox bzw sr_feuser_register
Ich arbeite mal das durch:
Es fehlt ein "i" im titel, kann das ein Mod editieren?
Ich hab das Plugin soweit drin, die Userlist funzt leider noch nicht.
Ich müsste danach nur noch die Felder etwas um ändern. Weiß jemand wie das geht?
Mein derzeitiges Problem:
Ich hab das Layout der Vistenkarte in dem Profiltemplate geändert. Aber wenn ich die Userlist anpassen will, benutzt er nicht alle Marker. Ich will ja das die VCards untereinander gezeigrt werden, eine Liste, und wollte dazu die Userlist "mißbrauchen" ... aber er zeigt dann nur die Hälfte der Marker ...
Sohn der Sonne schrieb... aber er zeigt dann nur die Hälfte der Marker ...
naja sind zuerst alle Marker ersetzt worden? Wenn ja, dann hast du sie zuviel im Template verschoben - auch das Template braucht - insb bei wiederkehrenden Elementen - eine gewisse Struktur, die man dann nur im php-Code anpassen kann
lg georg
Nee, die wurden von Anfang an nicht ersetzt. Ich verusche grade in der PHP Datei (sollte die /p1/.#class.tx_cwtcommunity_pi1.php.1.1 sein hoffe ich) das Marker Array um das der "My Profile" zu erweitern.
Hat geklappt. 🙂
Hänge jetzt daran neue Felder hinzuzufügen.
Sohn der Sonne schriebHat geklappt. 🙂
Hänge jetzt daran neue Felder hinzuzufügen.
tca.php erweitern, locallang entsprechend erweitern, gegebenfalls flexforms erweitern, .sql erweitern, fertig
Aber wie? Um was erweitern?
Was muss ich tun?
Es geht ja noch nicht mal um das Abckend, nur um das Frontedn von CWT Comm. Sollte eigentlich kein Problem sein ... sollte ...
Ich veröffentliche natürlich die gesamte Lösung wenn Sie da ist. 🙂
Unten sieht man was ich änderte.
Datei: p1/class.tx_cwtcommunity_pi1.php
elseif ($CODE == "PROFILE_EDIT"){
//Get the TCA from fe_users
//START CONFIG FOR FEEDIT
$table = "fe_users";
//Create Item array
$items['username']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_USERNAME_LABEL'));
$items['username']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_USERNAME_HELPTEXT'));
$items['username']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_USERNAME_ERRMSG'));
$items['username']['type'] = "preview";
$items['name']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_NAME_LABEL'));
$items['name']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_NAME_HELPTEXT'));
$items['name']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_NAME_ERRMSG'));
$items['password']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_PWD_LABEL'));
$items['password']['label_again'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_PWD_LABELAGAIN'));
$items['password']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_PWD_HELPTEXT'));
$items['password']['helptext_again'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_PWD_HELPTEXTAGAIN'));
$items['password']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_PWD_ERRMSG'));
$items["password"]["type"] = "password";
$items["password"]["eval"] = "twice";
$items['address']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_ADDRESS_LABEL'));
$items['address']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_ADDRESS_HELPTEXT'));
$items['address']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_ADDRESS_ERRMSG'));
$items['zip']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_ZIP_LABEL'));
$items['zip']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_ZIP_HELPTEXT'));
$items['zip']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_ZIP_ERRMSG'));
$items['city']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_CITY_LABEL'));
$items['city']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_CITY_HELPTEXT'));
$items['city']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_CITY_ERRMSG'));
$items['country']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_COUNTRY_LABEL'));
$items['country']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_COUNTRY_HELPTEXT'));
$items['country']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_COUNTRY_ERRMSG'));
$items['company']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_COMPANY_LABEL'));
$items['company']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_COMPANY_HELPTEXT'));
$items['company']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_COMPANY_ERRMSG'));
$items['telephone']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_PHONE_LABEL'));
$items['telephone']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_PHONE_HELPTEXT'));
$items['telephone']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_PHONE_ERRMSG'));
$items['fax']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_FAX_LABEL'));
$items['fax']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_FAX_HELPTEXT'));
$items['fax']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_FAX_ERRMSG'));
$items['email']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_EMAIL_LABEL'));
$items['email']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_EMAIL_HELPTEXT'));
$items['email']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_EMAIL_ERRMSG'));
$items["email"]["eval"] = "email";
$items['www']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_WWW_LABEL'));
$items['www']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_WWW_HELPTEXT'));
$items['www']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_WWW_ERRMSG'));
$items['tx_cwtcommunityuser_image']['label'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_IMAGE_LABEL'));
$items['tx_cwtcommunityuser_image']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_IMAGE_HELPTEXT'));
$items['tx_cwtcommunityuser_image']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_IMAGE_ERRMSG'));
//Edit Danny Faak
//Versuch ein neues Image-Feld hinzuzufügen
//
$items['tx_cwtcommunityuser_ppt']['label'] = htmlspecialchars("MOEP");
$items['tx_cwtcommunityuser_ppt']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_IMAGE_HELPTEXT'));
$items['tx_cwtcommunityuser_ppt']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_IMAGE_ERRMSG'));
//Ende Imagefeld
In der TCA.php weiß ich nicht was zu tun ist ... #angry#
und ich werd mir jetzt die Ext anschauen und schauen was du geändert hast? ne... ist aber auch egal!
siehe Core Api bzw manuals bzw videos zum Ext erstellen!
lg georg
So , kann erst heute wieder weitermachen. Habs aber immer noch nicht ... mal sehen. 🙂
just2b schriebSohn der Sonne schriebHat geklappt. 🙂
Hänge jetzt daran neue Felder hinzuzufügen.
tca.php erweitern, locallang entsprechend erweitern, gegebenfalls flexforms erweitern, .sql erweitern, fertig
Die tca.php bildet genau 6 Haupt-Arrays:
$TCA["tx_cwtcommunity_message"]
$TCA["tx_cwtcommunity_buddylist"]
$TCA["tx_cwtcommunity_buddylist_approval"]
$TCA["tx_cwtcommunity_guestbook"]
$TCA["tx_cwtcommunity_guestbook_data"]
$TCA["tx_cwtcommunity_icons"]
Und ich wüsste nicht welches davon ich editieren sollte.
Ziel soll es ja sein neue Profilfelder zu bekommen, die man dann editieren kann. Hauptziel dabei: Ein weiters Bild und eine Datei (*.ppt).
Die locallang muss angepasst werden, damit die neuen Felder Namen haben, klar.
Felxforms ... ich schau mir mal an was das ist, vom Namen her denke ich das sind die Eingabe-Forms?
.sql erweitern: Ich denke damit meinst du die Datenbank, das ist geschehen (Felder einfügen). 🙂
Also, ich hab das neue Feld unter Edit Profile.
Aber leider nutzt er nicht mein Datenbankfeld, sondern das normale Imagefeld.
Meine Änderungen:
Pfad: /cwt_community
Datei 1: locallang_tca.php
Berreich: Array 'de'
Änderung:
//Edit me
'cwt_community.pi_flexform.sheet_general' => 'Hauptseite',
'cwt_community.pi_flexform.sheet_general_code' => 'Wählen Sie Ihre Ansicht:',
'cwt_community.pi_flexform.sheet_general_code.I.0' => 'Willkommen',
'cwt_community.pi_flexform.sheet_general_code.I.1' => 'Nachrichten',
'cwt_community.pi_flexform.sheet_general_code.I.2' => 'Gästebuch',
'cwt_community.pi_flexform.sheet_general_code.I.3' => 'Nutzerprofil',
'cwt_community.pi_flexform.sheet_general_code.I.4' => 'Nutzerprofil editieren',
'cwt_community.pi_flexform.sheet_general_code.I.5' => 'Benutzerliste',
'cwt_community.pi_flexform.sheet_general_code.I.6' => 'Freunde',
//Ende Edit
Pfad: /cwt_community/p1
Datei 1: class.tx_cwtcommunity_pi1.php
Berreich 1: elseif ($CODE == "PROFILE_EDIT")
Änderung:
//Edit me
$items['tx_cwtcommunityuser_ppt']['label'] = htmlspecialchars("PowerPoint Datei:");
$items['tx_cwtcommunityuser_ppt']['helptext'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_IMAGE_HELPTEXT'));
$items['tx_cwtcommunityuser_ppt']['error_msg'] = htmlspecialchars($this->pi_getLL('CWT_PROFILE_EDIT_IMAGE_ERRMSG'));
//Ende Edit
Bereich 2: Create Form object
Änderung:
//Edit me
$content.= $form->getElement("tx_cwtcommunityuser_ppt");
//Ende edit
Berreich 3: Create Marker Array
Änderung:
//Edit me
$pathToImage = "uploads/tx_cwtcommunityuser/".$users[$i]['tx_cwtcommunityuser_ppt'];
$lConf = $this->conf['imagePopup.'];
$lConf['alttext']= "";
$markerArray["###PPT###"] = $cObj -> cImage($pathToImage, $lConf);
//Ende edit
Berreich 4: GetViewProfile
Änderung:
//Edit me
$pathToImage = "uploads/tx_cwtcommunityuser/".$user['tx_cwtcommunityuser_ppt'];
$lConf = $this->conf['imagePopup.'];
$lConf['alttext']= "";
//Ende Edit
Berreich 5: GetViewProfile: Create Marker Array
Änderung:
//Edit me
$markerArray["###PPT###"] = $cObj -> cImage($pathToImage, $lConf);
//Ende Edit
Berreich 6: function doGetUserlist($letter), im Else:
Änderung:
// Fetch users
//Edit me
$users = $this -> doDatabaseQuery("SELECT * FROM fe_users WHERE pid = ".intval($this->sysfolderList)." AND (username LIKE '" . $letter . "%' OR username LIKE '" . strtoupper($letter) . "%') AND NOT deleted=1 AND NOT disable=1 ORDER BY username ASC");
//Ende Edit
//Auskommentiert
// $users = $this -> doDatabaseQuery("SELECT uid, username, name, city, country, www FROM fe_users WHERE pid = ".intval($this->sysfolderList)." AND (username LIKE '" . $letter . "%' OR username LIKE '" . strtoupper($letter) . "%') AND NOT deleted=1 AND NOT disable=1 ORDER BY username ASC");
//Ende Auskommmentiert
Datei 2: locallang.php
Berreich: Array 'de'
Änderung:
//Edit me
//PPT
'CWT_PROFILE_EDIT_PPT_LABEL' => 'PowerPoint Datei:',
'CWT_PROFILE_EDIT_PPT_HELPTEXT' => 'Diese Datei wird im Profil gespeichert.',
//Edit Ende
Pfad: cwt_community_user
Datei: ext_tables.php
Berreich: Array tempColumns
Änderung:
//Edit me
"tx_cwtcommunityuser_ppt" => Array (
"exclude" => 1,
"label" => "LLL:EXT:cwt_community_user/locallang_db.php:fe_users.tx_cwtcommunityuser_ppt",
"config" => Array (
"type" => "group",
"internal_type" => "file",
"allowed" => $GLOBALS["TYPO3_CONF_VARS"]["GFX"]["imagefile_ext"],
"max_size" => 500,
"uploadfolder" => "uploads/tx_cwtcommunityuser",
"size" => 1,
"minitems" => 0,
"maxitems" => 1,
)
),
//Ende Edit
Berreich: Vorletzte Zeile
Änderung:
t3lib_extMgm::addToAllTCAtypes("fe_users","tx_cwtcommunityuser_image;;;;1-1-1,tx_cwtcommunityuser_ppt;;;;1-1-1, tx_cwtcommunityuser_sex");
Bemerkung: "tx_cwtcommunityuser_ppt;;;;1-1-1," wurde hinzugefügt.
Datei: ext_tables.sql
Berreich: CREATE TABLE fe_users
Änderung:
tx_cwtcommunityuser_ppt blob NOT NULL,
Die Bilder werden jedesmal in beide Datenbankfelder geschrieben, und auch jedesmal wenn gelöscht wird in beiden entfernt.