jak na razie to nie wiele zrobiłem ale zerknij. Oczywiście obrazki są poglądowe i wygląd standard. Jak zadziała algorytm obliczeń (jak go pojmę
) to zajmę się wyglądem, choć tak naprawdę to standardowy jest dość przyjemny dla oka. Osobiście wychodzę z założenie, że sklep ma być czytelny, bez wodotrysków i prosty w obsłudze. Mówiąc brzydko debilo-odporny. Za dużo bajerów rozprasza klienta, który nie zawsze jest być fanem komputerów
.
P.S.
- Kod: Zaznacz cały
public function write() {
$this->language->load('product/product');
$this->load->model('catalog/review');
$json = array();
if ($this->request->server['REQUEST_METHOD'] == 'POST') {
if ((utf8_strlen($this->request->post['name']) < 3) || (utf8_strlen($this->request->post['name']) > 25)) {
$json['error'] = $this->language->get('error_name');
}
if ((utf8_strlen($this->request->post['text']) < 25) || (utf8_strlen($this->request->post['text']) > 1000)) {
$json['error'] = $this->language->get('error_text');
}
if (empty($this->request->post['rating'])) {
$json['error'] = $this->language->get('error_rating');
}
if (empty($this->session->data['captcha']) || ($this->session->data['captcha'] != $this->request->post['captcha'])) {
$json['error'] = $this->language->get('error_captcha');
}
if (!isset($json['error'])) {
$this->model_catalog_review->addReview($this->request->get['product_id'], $this->request->post);
$json['success'] = $this->language->get('text_success');
}
}
$this->response->setOutput(json_encode($json));
}
Lokalizacja controller/produkt.
Co ta funkcja robi?? Zapisuje do ciastek??