diff --git a/ai/cs/@home.texy b/ai/cs/@home.texy
new file mode 100644
index 0000000000..e2385cdf80
--- /dev/null
+++ b/ai/cs/@home.texy
@@ -0,0 +1,11 @@
+Nette AI
+********
+
+- [Introduction |guide]
+- [Getting Started |getting-started]
+- [MCP Inspector |mcp-inspector]
+- [Claude Code |claude-code]
+- [Tips & Best Practices |tips]
+
+{{maintitle: Nette AI – Vibe Coding with Nette Framework}}
+{{description: Build Nette applications with AI assistance. MCP Inspector gives any AI tool deep knowledge of your application's DI container, database, routing, and errors. No hallucinations, just clean code.}}
diff --git a/ai/cs/@meta.texy b/ai/cs/@meta.texy
new file mode 100644
index 0000000000..e06cc9886c
--- /dev/null
+++ b/ai/cs/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette AI}}
diff --git a/ai/en/@home.texy b/ai/en/@home.texy
new file mode 100644
index 0000000000..e2385cdf80
--- /dev/null
+++ b/ai/en/@home.texy
@@ -0,0 +1,11 @@
+Nette AI
+********
+
+- [Introduction |guide]
+- [Getting Started |getting-started]
+- [MCP Inspector |mcp-inspector]
+- [Claude Code |claude-code]
+- [Tips & Best Practices |tips]
+
+{{maintitle: Nette AI – Vibe Coding with Nette Framework}}
+{{description: Build Nette applications with AI assistance. MCP Inspector gives any AI tool deep knowledge of your application's DI container, database, routing, and errors. No hallucinations, just clean code.}}
diff --git a/ai/en/@left-menu.texy b/ai/en/@left-menu.texy
new file mode 100644
index 0000000000..54132f474a
--- /dev/null
+++ b/ai/en/@left-menu.texy
@@ -0,0 +1,5 @@
+- [Introduction |guide]
+- [Getting Started |getting-started]
+- [MCP Inspector |mcp-inspector]
+- [Claude Code |claude-code]
+- [Tips & Best Practices |tips]
diff --git a/ai/en/@meta.texy b/ai/en/@meta.texy
new file mode 100644
index 0000000000..e06cc9886c
--- /dev/null
+++ b/ai/en/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette AI}}
diff --git a/ai/en/claude-code.texy b/ai/en/claude-code.texy
new file mode 100644
index 0000000000..f12fa5faf1
--- /dev/null
+++ b/ai/en/claude-code.texy
@@ -0,0 +1,251 @@
+Claude Code Plugin
+******************
+
+
+
+The Nette plugin gives Claude deep knowledge of the framework. Instead of generic PHP advice, you get recommendations that follow Nette conventions – from presenters and forms to Latte templates and database queries.
+
+The plugin includes:
+- **10 skills** covering all major areas of Nette development
+- **Automatic validation** that catches errors in Latte and NEON files
+- **MCP Inspector integration** for real-time application introspection
+
+
+
+
+Installation
+============
+
+If you haven't installed Claude Code yet, see the [complete setup guide |getting-started]. Once Claude Code is running, install the Nette plugin:
+
+```shell
+/plugin marketplace add nette/claude-code
+/plugin install nette@nette
+```
+
+
+How Skills Work
+===============
+
+You don't need to activate skills manually. They turn on automatically based on what you're talking about.
+
+- Ask about "presenter structure" → the `nette-architecture` skill activates
+- Ask about "form validation" → the `nette-forms` skill activates
+- Ask about "Latte filters" → the `latte-templates` skill activates
+
+This means you get relevant, context-aware help without having to think about which skill you need.
+
+
+Available Skills
+================
+
+Here's what each skill covers:
+
+
+nette-architecture
+------------------
+
+When you're designing your application structure, this skill guides you through:
+
+- **Directory organization** – Where to put presenters, services, entities, and components
+- **Module design** – How to split your application into logical modules (Admin, Front, Api)
+- **Presenter patterns** – When to use base presenters, how to handle authentication
+- **Evolution strategy** – Start minimal, grow organically, refactor when needed
+
+The key principle: Don't over-engineer. Create subdirectories when you have 5+ related files, not before.
+
+
+nette-configuration
+-------------------
+
+Everything about the DI container and NEON configuration:
+
+- **Service registration** – How to define services in `services.neon`
+- **Autowiring** – When it works automatically and when you need explicit configuration
+- **Parameters** – How to use configuration parameters across your application
+- **Extensions** – Working with DI extensions from Nette and third parties
+
+
+nette-database
+--------------
+
+Covers both the raw SQL approach and the Database Explorer:
+
+- **Database Explorer** – Using `Selection` for queries, `ActiveRow` for entities
+- **Entity conventions** – The `Row` suffix pattern, type hints with `@property-read`
+- **Relationships** – Navigating foreign keys with colon notation
+- **When to use what** – Explorer for CRUD, raw SQL for complex analytics
+
+Example: Claude knows that `->where('category.slug', $slug)` automatically joins the category table.
+
+
+nette-forms
+-----------
+
+Creating and handling forms the Nette way:
+
+- **Controls** – All built-in controls from text inputs to file uploads
+- **Validation** – Built-in rules, custom validators, conditional validation
+- **Rendering** – Manual rendering, Bootstrap integration, custom renderers
+- **Patterns** – Create/edit forms, form components, AJAX submissions
+
+
+nette-schema
+------------
+
+Data validation and normalization with the Schema component:
+
+- **Expect class** – Building validation schemas for arrays and objects
+- **Configuration schemas** – Validating NEON configuration in DI extensions
+- **Type coercion** – Automatic conversion of strings to integers, dates, etc.
+- **Custom validators** – Adding your own validation rules
+
+Example: Claude knows how to create schemas like:
+
+```php
+$schema = Expect::structure([
+ 'name' => Expect::string()->required(),
+ 'age' => Expect::int()->min(0)->max(120),
+ 'email' => Expect::string(),
+ 'roles' => Expect::listOf('string')->default([]),
+]);
+```
+
+
+nette-testing
+-------------
+
+Writing tests with Nette Tester:
+
+- **Test structure** – The `.phpt` format, `@testCase` annotation, file organization
+- **Assertions** – All `Assert::*` methods: `same()`, `equal()`, `exception()`, `match()`, and more
+- **Fixtures** – Setting up test data, mocking dependencies, database transactions
+- **Running tests** – Command-line options, parallel execution, code coverage
+
+Example: Claude can generate proper test files:
+
+```php
+/** @testCase */
+class UserServiceTest extends TestCase
+{
+ public function testCreateUser(): void
+ {
+ $service = new UserService($this->mockDatabase());
+ $user = $service->create(['name' => 'John']);
+ Assert::same('John', $user->name);
+ }
+}
+```
+
+
+nette-utils
+-----------
+
+The utility classes that make PHP development easier:
+
+- **Arrays** – `Nette\Utils\Arrays` with `get()`, `getRef()`, `map()`, `flatten()`, and more
+- **Strings** – Unicode-safe operations: `webalize()`, `truncate()`, `contains()`, `startsWith()`
+- **Finder** – File system traversal with filtering by name, size, date
+- **Image** – Resize, crop, sharpen with automatic format detection
+- **Json** – Safe JSON encoding/decoding with proper error handling
+- **Validators** – Email, URL, numeric validation helpers
+- **DateTime** – Immutable date/time with Czech locale support
+
+
+frontend-development
+--------------------
+
+Integrating frontend tools with Nette:
+
+- **Vite** – Setting up Vite for modern JavaScript/TypeScript development, HMR configuration
+- **Nette Assets** – Using the asset system for cache-busted URLs in production
+- **Tailwind CSS** – Configuration for Tailwind with Latte templates, purging unused styles
+- **ESLint & Prettier** – Code quality tools integration
+- **Build scripts** – npm/package.json scripts for development and production builds
+
+Claude can help configure `vite.config.js` to work with Nette's directory structure and generate proper asset references in Latte templates.
+
+
+latte-templates
+---------------
+
+Everything about the Latte templating engine:
+
+- **Syntax** – Tags, filters, blocks, and inheritance
+- **Security** – Auto-escaping, content-aware output
+- **Custom filters** – Creating and registering your own filters
+- **Template classes** – Using typed templates for better IDE support
+
+
+neon-format
+-----------
+
+The NEON configuration format:
+
+- **Syntax** – Mappings, sequences, entities, and multiline strings
+- **Common patterns** – Service definitions, parameter references
+- **Debugging** – Finding and fixing syntax errors
+
+
+Automatic Validation
+====================
+
+One of the most useful features is automatic validation. After every file edit, the plugin checks for errors:
+
+| What | How It Works |
+|------|--------------|
+| **Latte templates** | Runs `latte-lint` to check syntax after every `.latte` edit |
+| **NEON files** | Validates NEON syntax after every `.neon` edit |
+| **Tracy errors** | Watches the exception log and alerts Claude about new errors |
+
+If there's a syntax error in your Latte template, Claude knows about it immediately and can suggest a fix. No more discovering errors in the browser.
+
+
+Plugin for Framework Contributors
+=================================
+
+If you're contributing to Nette itself, there's an additional plugin with coding standards:
+
+```shell
+/plugin install nette-dev@nette
+```
+
+| Skill | What It Covers |
+|-------|----------------|
+| `php-coding-standards` | Nette's PHP coding style – indentation, naming, structure |
+| `php-doc` | PHPDoc conventions – when to document, what format to use |
+| `commit-messages` | How to write commit messages for Nette repositories |
+
+
+Automatic PHP Style Fixing
+==========================
+
+For automatic code style fixing after every PHP file edit, install the optional php-fixer plugin:
+
+```shell
+/plugin install php-fixer@nette
+/install-php-fixer
+```
+
+The second command installs `nette/coding-standard` globally. After that, every PHP file you edit will be automatically formatted according to Nette coding standards.
+
+
+MCP Inspector Integration
+=========================
+
+The plugin works even better with [MCP Inspector |mcp-inspector] – a tool that lets Claude see your actual application state. With MCP Inspector, Claude can:
+
+- Query your real database schema instead of guessing
+- List your registered DI services and their configuration
+- Read Tracy error logs for debugging
+- Match URLs to presenters using your actual routes
+
+Install it with a single command:
+
+```shell
+/install-mcp-inspector
+```
+
+Then restart Claude Code. See the [MCP Inspector documentation |mcp-inspector] for all 20 available tools.
+
+{{composer: nette/claude-code}}
diff --git a/ai/en/getting-started.texy b/ai/en/getting-started.texy
new file mode 100644
index 0000000000..fa20b5da1f
--- /dev/null
+++ b/ai/en/getting-started.texy
@@ -0,0 +1,260 @@
+Getting Started
+***************
+
+
+
+Ready to try [vibe coding |guide] with Nette? This guide walks you through the complete setup:
+
+- Choosing and installing an AI tool
+- Setting up MCP Inspector so AI can see your application
+- Making your first AI-assisted changes
+
+The whole process takes about 10 minutes. Let's get started!
+
+
+
+
+Choosing Your AI Tool
+=====================
+
+Nette AI tools work with any MCP-compatible AI assistant. We recommend **Claude Code** for the best experience – it has a dedicated Nette plugin with deep framework knowledge and automatic code validation.
+
+Other options include **Cursor**, **VS Code with Continue**, and other MCP-compatible tools. See [Other AI Tools |#other-ai-tools] at the end of this guide.
+
+
+What You'll Need
+================
+
+Before we begin, make sure you have:
+
+- **A Nette project** – existing or new (`composer create-project nette/web-project`)
+- **PHP 8.2+** – required for MCP Inspector
+- **An AI tool** – we'll install Claude Code below (Claude Pro costs $20/month)
+
+
+Installation on macOS and Linux
+===============================
+
+```shell
+curl -fsSL https://claude.ai/install.sh | bash
+```
+
+On macOS, you can alternatively use Homebrew:
+
+```shell
+brew install --cask claude-code
+```
+
+After installation, skip to [Starting Claude Code |#starting-claude-code].
+
+
+Installation on Windows via WSL
+===============================
+
+Claude Code requires a Unix environment. On Windows, use WSL:
+
+```shell
+wsl --install
+```
+
+This installs Ubuntu. **Restart your computer** after installation.
+
+After restart, launch Ubuntu:
+
+```shell
+ubuntu
+```
+
+First launch will ask for a username and password – you'll need it for `sudo` later.
+
+Installing Claude Code in WSL in the Ubuntu terminal:
+
+```shell
+curl -fsSL https://claude.ai/install.sh | bash
+```
+
+Your Windows drives are mounted under `/mnt/`:
+- `C:\Users\Jan\Projects` → `/mnt/c/Users/Jan/Projects`
+- `D:\Work` → `/mnt/d/Work`
+
+From Windows, access Linux files via `\\wsl$\Ubuntu\home\username` in Explorer.
+
+
+Starting Claude Code
+====================
+
+Great, you have Claude Code installed! Let's start it up.
+
+Navigate to your project directory:
+
+```shell
+# Windows (WSL)
+cd /mnt/c/Users/Jan/Projects/my-app
+
+# macOS/Linux
+cd ~/projects/my-app
+```
+
+Start Claude Code:
+
+```shell
+claude
+```
+
+The first time you run it, Claude Code will ask you to authenticate. It will open a browser window where you can log in to your Anthropic account. After successful authentication, you'll see the `claude>` prompt and you're ready to go.
+
+You can also use Claude Code "on the web":https://claude.ai/code or via the "desktop app":https://claude.com/download, but local installation provides the best experience with direct file access.
+
+
+Adding the Nette Plugin
+=======================
+
+Now let's give Claude deep knowledge of Nette. First, add the Nette marketplace and enable auto-updating:
+
+```shell
+/plugin marketplace add nette/claude-code
+```
+
+Then install the plugin:
+
+```shell
+/plugin install nette@nette
+```
+
+That's it! The plugin is now active. It includes 10 specialized skills that automatically activate based on what you're working on. When you ask about forms, it knows about Nette Forms. When you ask about templates, it knows about Latte.
+
+
+Setting Up MCP Inspector
+========================
+
+The final piece is MCP Inspector, which lets Claude see your actual application – your services, database schema, routes, and error logs.
+
+The easiest way to install it is through Claude Code:
+
+```shell
+/install-mcp-inspector
+```
+
+This command adds the `nette/mcp-inspector` package to your project and configures everything automatically.
+
+Alternatively, you can install it manually with Composer:
+
+```shell
+composer require nette/mcp-inspector
+```
+
+**Important:** After installing MCP Inspector, restart Claude Code (type `/exit` and run `claude` again) to activate the connection.
+
+
+Testing Your Setup
+==================
+
+Let's verify everything works. Try these prompts:
+
+
+Test the Plugin Knowledge
+-------------------------
+
+Type:
+
+```
+What's the recommended directory structure for a Nette application?
+```
+
+Claude should respond with detailed information about presenters, models, templates, and configuration – knowledge that comes from the `nette-architecture` skill.
+
+
+Test MCP Inspector
+------------------
+
+Type:
+
+```
+What services do I have registered in my DI container?
+```
+
+If MCP Inspector is working, Claude will call `di_get_services()` and show you the actual services from your application. If you see a list of your real services, congratulations – everything is set up correctly!
+
+
+Test Database Introspection
+---------------------------
+
+If your application uses a database, try:
+
+```
+What tables do I have? Show me the columns in the user table.
+```
+
+
+Your First Real Task
+====================
+
+Now that everything is set up, let's do something useful. Try this prompt:
+
+```
+I need a simple ArticlePresenter with list and detail actions.
+Generate the presenter, templates, and tell me what routes I need.
+```
+
+Watch as Claude generates a complete, working presenter following Nette conventions. It will:
+- Create the presenter class with proper type hints
+- Generate Latte templates for both actions
+- Suggest the appropriate route configuration
+
+If you have MCP Inspector set up and an `article` table in your database, try:
+
+```
+Look at my article table and generate an ArticleRow entity with proper type hints.
+```
+
+
+Other AI Tools
+==============
+
+While we recommend Claude Code for the best Nette experience, MCP Inspector works with any MCP-compatible tool.
+
+
+Cursor
+------
+
+Cursor is a popular AI-first code editor. To use MCP Inspector with Cursor:
+
+1. Install MCP Inspector: `composer require nette/mcp-inspector`
+2. Create `.cursor/mcp.json` in your project:
+
+```json
+{
+ "mcpServers": {
+ "nette-inspector": {
+ "command": "php",
+ "args": ["vendor/bin/mcp-inspector"]
+ }
+ }
+}
+```
+
+3. Restart Cursor
+
+Note: Cursor doesn't have the Nette-specific skills that the Claude Code plugin provides, but MCP Inspector will still give it access to your application's services, database, routes, and logs.
+
+
+VS Code + Continue
+------------------
+
+Continue is an open-source AI coding assistant for VS Code. Configure MCP Inspector in Continue's settings following their MCP documentation.
+
+
+Other MCP Tools
+---------------
+
+Any tool supporting the Model Context Protocol can use MCP Inspector. See the [MCP Inspector manual configuration |mcp-inspector#manual-mcp-configuration] for setup instructions.
+
+
+What's Next
+===========
+
+You're now ready for AI-assisted Nette development! Here's where to go from here:
+
+- [MCP Inspector |mcp-inspector] – Learn about all 20 introspection tools
+- [Claude Code Plugin |claude-code] – Explore all 13 skills (Claude Code users)
+- [Tips & Best Practices |tips] – Get the most out of your AI assistant
diff --git a/ai/en/guide.texy b/ai/en/guide.texy
new file mode 100644
index 0000000000..b0d98486c5
--- /dev/null
+++ b/ai/en/guide.texy
@@ -0,0 +1,128 @@
+Vibe Coding
+***********
+
+
+
+Vibe coding is a new way of programming where you describe what you want in plain language and AI writes the code for you. Nette is ideal for this style of development – strict dependency injection, strong typing, and clear conventions allow AI to generate precise, working code.
+
+- **MCP Inspector** – Gives any AI tool real-time access to your application
+- **Claude Code Plugin** – Deep Nette knowledge for Claude Code users
+- **Best Practices** – Proven patterns for effective AI collaboration
+
+
+
+
+What is Vibe Coding?
+====================
+
+"The hottest new programming language is English."
+
+That's the core idea behind vibe coding – instead of writing every line yourself, you describe your intent and let AI handle the implementation. Want a presenter for managing products? Just say so. Need a form with validation? Describe the fields and rules.
+
+But here's the important part: **AI doesn't replace programmers**. It's a powerful assistant that accelerates routine work:
+
+- Generate boilerplate code (presenters, forms, entities) in seconds
+- Understand existing code and explain how it works
+- Find bugs and suggest fixes
+- Write tests based on your implementation
+
+The catch? AI doesn't truly know your application. It sees only what you show it and guesses the rest based on patterns it learned during training. That's where Nette AI tools come in.
+
+
+Why Nette is Perfect for AI
+===========================
+
+Not all frameworks work equally well with AI. Nette has properties that make it exceptionally suited for AI-assisted development:
+
+**Strict Dependency Injection**
+
+In Nette, all services are registered in the DI container. AI can inspect exactly what services exist and how they're configured – no guessing required.
+
+**Strong Typing**
+
+Type hints on methods and properties mean AI generates code that actually works. Fewer runtime errors, less debugging.
+
+**Clear Conventions**
+
+Presenters, components, templates – everything has its place. AI can follow these patterns and produce code that looks like it was written by an experienced Nette developer.
+
+The key principle:
+
+.**"Without MCP, AI guesses. With MCP, AI knows."**
+
+
+How It Works
+============
+
+The magic happens through **MCP (Model Context Protocol)** – an open standard for connecting AI assistants to external data sources. Instead of guessing based on training data, AI can query your actual application state.
+
+Here's the flow:
+
+1. **You** describe what you want: "Create an entity for the product table"
+2. **AI tool** (Claude, Cursor, etc.) needs to know your database schema
+3. **MCP Inspector** queries your application and returns the actual schema
+4. **AI** generates code that matches your real database
+
+No hallucinations. No guessing. Just accurate code.
+
+
+Nette AI Tools
+==============
+
+
+MCP Inspector
+-------------
+
+The core of Nette's AI integration. MCP Inspector is an MCP server that gives **any compatible AI tool** real-time access to your application:
+
+| What AI Can See | Examples |
+|-----------------|----------|
+| **DI Container** | Services, parameters, extensions |
+| **Database** | Tables, columns, relationships |
+| **Router** | Routes, URL matching, generation |
+| **Tracy** | Exceptions, warnings, logs |
+
+MCP Inspector works with Claude Code, Cursor, VS Code with Continue, and any other tool that supports the MCP protocol.
+
+[Learn more about MCP Inspector |mcp-inspector]
+
+
+Claude Code Plugin
+------------------
+
+For users of Claude Code, there's an additional plugin that gives Claude deep knowledge of Nette conventions. It includes 10 specialized "skills" that activate automatically:
+
+| Skill | What It Covers |
+|-------|----------------|
+| nette-architecture | Presenters, modules, directory structure |
+| nette-database | Database Explorer, entities, queries |
+| nette-forms | Controls, validation, rendering |
+| latte-templates | Syntax, filters, security |
+| + 6 more... | [See complete list |claude-code] |
+
+The plugin also automatically validates Latte templates and NEON files after every edit.
+
+[Learn more about Claude Code Plugin |claude-code]
+
+
+Other AI Tools
+--------------
+
+MCP Inspector works with any MCP-compatible tool. Setup guides for additional tools are coming soon:
+
+- **Cursor** – Popular AI-first code editor
+- **VS Code + Continue** – Open-source AI coding assistant
+- **Gemini CLI** – Google's command-line AI tool
+
+
+Getting Started
+===============
+
+Ready to try vibe coding with Nette? The setup takes about 10 minutes:
+
+1. **Choose your AI tool** – We recommend Claude Code for the best Nette experience
+2. **Install MCP Inspector** – The core that gives AI access to your application
+3. **Start coding** – Describe what you want and let AI help
+
+[Complete setup guide |getting-started]
+
diff --git a/ai/en/mcp-inspector.texy b/ai/en/mcp-inspector.texy
new file mode 100644
index 0000000000..5965a94677
--- /dev/null
+++ b/ai/en/mcp-inspector.texy
@@ -0,0 +1,448 @@
+MCP Inspector
+*************
+
+
+
+MCP Inspector is the bridge between **any AI tool** and your Nette application. It allows AI assistants to look directly at your running app – to see what services you have registered, what your database schema looks like, which routes are defined, and what errors have occurred.
+
+This is what makes the difference between AI that guesses and AI that knows.
+
+
+
+
+Supported AI Tools
+==================
+
+MCP Inspector works with any tool that supports the **Model Context Protocol (MCP)**:
+
+- **[Claude Code |claude-code]** – Full support with dedicated Nette plugin
+- **Cursor** – Configure via `.cursor/mcp.json`
+- **VS Code + Continue** – Configure via Continue settings
+- **Any MCP-compatible tool** – See [manual configuration |#manual-mcp-configuration]
+
+
+Why MCP Matters
+===============
+
+Imagine you ask your AI: "Generate an entity for the product table."
+
+Without MCP Inspector, the AI has to guess what columns your table has. It might assume common patterns like `id`, `name`, `price` – but what if your table has different columns? What if `price` is called `unit_price`? What if you have a `currency_id` foreign key?
+
+With MCP Inspector, the AI doesn't guess. It calls `db_get_columns("product")` and sees your actual schema:
+
+The result is code that actually works with your database, not code you have to fix.
+
+
+Installation
+============
+
+If you're using the [Nette plugin for Claude Code |claude-code], installation is simple:
+
+```shell
+/install-mcp-inspector
+```
+
+This command adds `nette/mcp-inspector` to your project and configures everything automatically.
+
+For other AI tools or manual installation:
+
+```shell
+composer require nette/mcp-inspector
+```
+
+Then configure your AI tool to use the MCP server – see [manual configuration |#manual-mcp-configuration] below.
+
+**Important:** After installation, restart your AI tool. The MCP server only connects when the tool starts.
+
+
+How It Works
+============
+
+MCP Inspector runs as a background process that your AI tool can communicate with. When AI needs information about your application, it sends a request to MCP Inspector, which:
+
+1. Loads your application's DI container (using `App\Bootstrap`)
+2. Executes the requested query (get services, read database schema, etc.)
+3. Returns the result to the AI
+
+All operations are **read-only**. MCP Inspector can't modify your database, change configuration, or execute commands.
+
+
+DI Container Tools
+==================
+
+These tools let AI explore your service definitions.
+
+
+di_get_services
+---------------
+
+Lists all registered services. You can filter by name or type.
+
+When AI asks "What mail services do I have?", it calls:
+
+```
+di_get_services("mail")
+```
+
+And gets a list like:
+
+```
+- mail.mailer (Nette\Mail\Mailer)
+- App\Model\QueueMailer
+- App\Core\SmtpTransport
+```
+
+
+di_get_service
+--------------
+
+Gets detailed information about a specific service – how it's created, what setup methods are called, what tags it has.
+
+
+di_get_parameters
+-----------------
+
+Reads configuration parameters. Want to know what your database settings are?
+
+```
+di_get_parameters("database")
+```
+
+Note: Sensitive values (passwords, tokens, API keys) are automatically masked.
+
+
+di_find_by_tag
+--------------
+
+Finds services with a specific tag. Useful for discovering CLI commands:
+
+```
+di_find_by_tag("console.command")
+```
+
+
+di_find_by_type
+---------------
+
+Finds services implementing a specific interface:
+
+```
+di_find_by_type("Nette\\Security\\Authenticator")
+```
+
+
+di_get_extensions
+-----------------
+
+Lists all registered DI extensions with their configuration.
+
+
+Database Tools
+==============
+
+These tools give AI visibility into your database structure.
+
+
+db_get_tables
+-------------
+
+Lists all tables in your database.
+
+
+db_get_columns
+--------------
+
+Gets detailed column information for a table – types, whether they're nullable, default values, and foreign key relationships.
+
+```
+db_get_columns("order")
+```
+
+Returns something like:
+
+```
+- id: int (PRIMARY KEY)
+- customer_id: int (FK → customer.id)
+- status: varchar(20)
+- total: decimal(10,2)
+- created_at: datetime
+```
+
+
+db_get_relationships
+--------------------
+
+Shows all foreign key relationships in your database – which tables reference which other tables.
+
+
+db_get_indexes
+--------------
+
+Lists indexes for a specific table.
+
+
+db_explain_query
+----------------
+
+Runs `EXPLAIN` on a SELECT query to analyze its performance. AI can use this to suggest query optimizations.
+
+
+db_generate_entity
+------------------
+
+The most useful tool for quick development. Given a table name, it generates a complete PHP entity class with proper type hints:
+
+```
+db_generate_entity("product")
+```
+
+Generates:
+
+```php
+/**
+ * @property-read int $id
+ * @property-read string $name
+ * @property-read float $unit_price
+ * @property-read ?CategoryRow $category
+ * @property-read DateTimeImmutable $created_at
+ */
+final class ProductRow extends Table\ActiveRow
+{
+}
+```
+
+
+Router Tools
+============
+
+These tools help AI understand your URL structure.
+
+
+router_get_routes
+-----------------
+
+Lists all registered routes with their masks and default values.
+
+
+router_match_url
+----------------
+
+Given a URL, finds which presenter and action handles it:
+
+```
+router_match_url("/admin/products/edit/5")
+```
+
+Returns:
+
+```
+Presenter: Admin:Product
+Action: edit
+Parameters: id=5
+```
+
+
+router_generate_url
+-------------------
+
+Generates a URL for a given presenter and action:
+
+```
+router_generate_url("Admin:Product:edit", {"id": 5})
+```
+
+
+Tracy Tools
+===========
+
+These tools let AI see error logs and help with debugging. They're incredibly useful when something goes wrong – instead of you describing the error, AI can read it directly.
+
+
+tracy_get_last_exception
+------------------------
+
+Gets the most recent exception from Tracy's log, including the full stack trace. When something breaks, this is the first thing AI checks.
+
+```
+tracy_get_last_exception()
+```
+
+Returns the exception class, message, file, line number, and complete stack trace. AI can analyze this to identify the root cause and suggest a fix.
+
+Example response:
+```
+Exception: Nette\Database\UniqueConstraintViolationException
+Message: Duplicate entry 'john@example.com' for key 'email'
+File: /app/Model/UserService.php:45
+Stack trace:
+ #0 /app/Presentation/Admin/UserPresenter.php:32
+ #1 /vendor/nette/application/src/...
+```
+
+
+tracy_get_exceptions
+--------------------
+
+Lists recent exception files from Tracy's log directory. Useful for finding patterns or recurring issues.
+
+```
+tracy_get_exceptions(5)
+```
+
+Returns the 5 most recent exception files with timestamps. You can then use `tracy_get_exception_detail` to examine any of them.
+
+
+tracy_get_exception_detail
+--------------------------
+
+Gets the complete details of a specific exception file. Use this when you want to examine an older exception, not just the latest one.
+
+```
+tracy_get_exception_detail("exception-2024-01-15-143022-abc123.html")
+```
+
+
+tracy_get_warnings
+------------------
+
+Shows recent PHP warnings and notices from Tracy's log. These often indicate problems that don't crash the application but should be fixed.
+
+```
+tracy_get_warnings(10)
+```
+
+Common warnings AI can help fix:
+- Undefined array key
+- Deprecated function calls
+- Type mismatch warnings
+
+
+tracy_get_log
+-------------
+
+Reads entries from any Tracy log level. Tracy supports multiple log files: `error.log`, `warning.log`, `info.log`, and custom levels.
+
+```
+tracy_get_log("error", 20)
+```
+
+This reads the last 20 entries from the error log. Useful for seeing a history of issues, not just the most recent one.
+
+
+Creating Custom Tools
+=====================
+
+You can extend MCP Inspector with your own tools. This is useful if you have application-specific data that AI should be able to query.
+
+Create a class implementing the `Toolkit` interface:
+
+```php
+use Mcp\Capability\Attribute\McpTool;
+use Nette\McpInspector\Toolkit;
+use Nette\McpInspector\Bridge\BootstrapBridge;
+
+class OrderToolkit implements Toolkit
+{
+ public function __construct(
+ private BootstrapBridge $bridge,
+ ) {}
+
+ /**
+ * Get pending orders count and total value.
+ */
+ #[McpTool(name: 'orders_get_pending_summary')]
+ public function getPendingSummary(): array
+ {
+ $db = $this->bridge->getContainer()
+ ->getByType(Nette\Database\Explorer::class);
+
+ $result = $db->table('order')
+ ->where('status', 'pending')
+ ->select('COUNT(*) AS count, SUM(total) AS total')
+ ->fetch();
+
+ return [
+ 'count' => $result->count,
+ 'total' => $result->total,
+ ];
+ }
+}
+```
+
+Register it in `mcp-config.neon`:
+
+```neon
+toolkits:
+ - App\Mcp\OrderToolkit
+```
+
+Now AI can call `orders_get_pending_summary()` to get real-time order statistics.
+
+
+Configuration
+=============
+
+MCP Inspector works out of the box with the default Nette project structure. If your setup is different, create `mcp-config.neon` in your project root:
+
+```neon
+# Path to Bootstrap file (if not in default location)
+bootstrap: src/Bootstrap.php
+
+# Bootstrap class name (if different from default)
+bootstrapClass: MyApp\Bootstrap
+
+# Additional custom toolkits
+toolkits:
+ - App\Mcp\OrderToolkit
+ - App\Mcp\CustomerToolkit
+```
+
+
+Manual MCP Configuration
+------------------------
+
+For AI tools other than Claude Code (which configures automatically via the plugin), add MCP Inspector to your tool's configuration:
+
+**For most MCP-compatible tools**, create `.mcp.json` in your project root:
+
+```json
+{
+ "mcpServers": {
+ "nette-inspector": {
+ "command": "php",
+ "args": ["vendor/bin/mcp-inspector"]
+ }
+ }
+}
+```
+
+**For Cursor**, add to `.cursor/mcp.json`:
+
+```json
+{
+ "mcpServers": {
+ "nette-inspector": {
+ "command": "php",
+ "args": ["vendor/bin/mcp-inspector"]
+ }
+ }
+}
+```
+
+Consult your AI tool's documentation for the exact configuration location.
+
+
+Security Considerations
+=======================
+
+MCP Inspector is designed for development environments. Here's what you should know:
+
+**Read-only by design** – All tools only read data, never modify it.
+
+**Database protection** – The `db_explain_query` tool only accepts SELECT, SHOW, DESCRIBE, and EXPLAIN queries. INSERT, UPDATE, DELETE, and other modifying queries are rejected.
+
+**Sensitive data masking** – Configuration values containing words like "password", "secret", "token", or "apikey" are automatically masked with `***MASKED***`.
+
+**Do not expose in production** – MCP Inspector should only run on development machines. It provides detailed information about your application internals that you don't want exposed publicly.
+
+{{composer: nette/mcp-inspector}}
diff --git a/ai/en/tips.texy b/ai/en/tips.texy
new file mode 100644
index 0000000000..586f558519
--- /dev/null
+++ b/ai/en/tips.texy
@@ -0,0 +1,296 @@
+Tips for AI-Assisted Development
+********************************
+
+
+
+AI is a powerful tool, but like any tool, you get better results when you know how to use it well. This page collects practical advice from real-world experience with AI-assisted Nette development.
+
+- How to write prompts that get better results
+- Making the most of MCP Inspector
+- Proven workflows for common tasks
+- Mistakes to avoid
+
+
+
+
+Writing Better Prompts
+======================
+
+
+The Art of Being Specific
+-------------------------
+
+The single biggest improvement you can make is being specific. Compare these two prompts:
+
+**Vague prompt:**
+
+```
+Create a form
+```
+
+This gives the AI almost no context. What form? What fields? What validation? The AI has to make assumptions, and those assumptions might not match what you need.
+
+**Specific prompt:**
+
+```
+Create a ProductForm with:
+- name: text field, required, max 100 characters
+- price: float field, required, must be positive
+- description: textarea, optional
+- category: select from CategoryRow entities
+
+Use Bootstrap 5 rendering. The form should work for both creating new products and editing existing ones.
+```
+
+Now the AI knows exactly what you need and can generate code that works on the first try.
+
+
+Point to Existing Patterns
+--------------------------
+
+Your codebase already has patterns. Instead of explaining them, point the AI to examples:
+
+```
+Create an OrderPresenter. Follow the same patterns as ProductPresenter –
+same structure, same way of handling forms, same template organization.
+```
+
+The AI will read ProductPresenter and replicate the patterns you're already using.
+
+
+Let MCP Do the Heavy Lifting
+----------------------------
+
+If you have MCP Inspector installed (and you should!), don't explain your application – let the AI discover it:
+
+**Instead of:**
+
+```
+My product table has columns: id (int), name (varchar), price (decimal),
+category_id (int, foreign key to category), created_at (datetime)...
+```
+
+**Just say:**
+
+```
+Generate an entity for the product table.
+```
+
+The AI will call `db_get_columns("product")` and see the actual schema. The generated entity will match your real database, including any columns you might have forgotten to mention.
+
+
+Give Context About Your Goals
+-----------------------------
+
+AI can't read your mind. If there's a reason behind your request, share it:
+
+```
+I need to optimize the product listing page. It's currently loading
+all products at once, which is slow when there are thousands of items.
+The page needs to support filtering by category and sorting by price or name.
+```
+
+This helps the AI suggest an appropriate solution (pagination, lazy loading, caching) rather than just blindly implementing what you asked for.
+
+
+Working with MCP Inspector
+==========================
+
+MCP Inspector is most powerful when you use it strategically.
+
+
+Explore Before You Build
+------------------------
+
+Starting a new feature? Let the AI understand the context first:
+
+```
+I'm going to add order tracking. Before we start:
+1. What services do I have related to orders?
+2. What does my order table look like?
+3. What routes handle order-related pages?
+```
+
+This gives the AI context about your existing code, so the new feature fits naturally.
+
+
+Debug Smarter
+-------------
+
+When something goes wrong, don't describe the error – let the AI see it:
+
+```
+Something broke. Check the Tracy log for the last exception
+and tell me what went wrong.
+```
+
+The AI will call `tracy_get_last_exception()`, read the stack trace, and can often identify the problem faster than you could explain it.
+
+
+Verify Before You Create
+------------------------
+
+Before adding new routes or links, verify what exists:
+
+```
+What presenter handles /admin/products/edit? I want to make sure
+I'm not creating something that conflicts.
+```
+
+
+Common Workflows
+================
+
+Here are proven approaches for common tasks.
+
+
+Creating a Complete CRUD
+------------------------
+
+Don't ask for one piece at a time. Give the AI the full picture:
+
+```
+Create a complete CRUD for managing products:
+
+1. ProductPresenter with actions: list, add, edit, delete
+2. ProductForm as a component (works for both add and edit)
+3. Latte templates for all actions
+4. Route suggestions
+
+Use the actual product table schema. Follow the patterns
+in CategoryPresenter if it exists.
+```
+
+
+Adding a New Feature
+--------------------
+
+Break it down into phases that build on each other:
+
+```
+I need to add customer reviews to products.
+
+Phase 1 - Data layer:
+- Look at the product table
+- Suggest the review table schema
+- Create ReviewRow entity
+
+Phase 2 - Business logic:
+- Create ReviewService for CRUD operations
+- Add methods to get reviews for a product
+
+Phase 3 - UI:
+- Add review display to ProductPresenter:detail
+- Create ReviewForm for submitting reviews
+```
+
+
+Refactoring Existing Code
+-------------------------
+
+Let the AI understand before it changes:
+
+```
+Analyze the OrderService class. What does each method do?
+Are there any code smells or improvements you'd suggest?
+```
+
+Then:
+
+```
+The calculateTotal method is doing too much. Split it into
+smaller methods while keeping the same public interface.
+```
+
+
+Mistakes to Avoid
+=================
+
+
+Not Reviewing Generated Code
+----------------------------
+
+AI generates code quickly, but that doesn't mean every line is perfect. Always review:
+
+- **Database queries** – Are they efficient? Do they need indexes?
+- **Security** – Is input validated? Are there authorization checks?
+- **Edge cases** – What happens with empty data? Null values?
+
+AI is very good, but it's still an assistant. You're the developer responsible for the final code.
+
+
+Ignoring Validation Feedback
+----------------------------
+
+If you're using the [Claude Code plugin |claude-code], it validates your Latte templates and NEON files automatically. When it reports an error, the AI knows about it. Instead of manually fixing the error, just say:
+
+```
+Fix the error you just created.
+```
+
+The AI will read the validation output and correct the mistake.
+
+
+Forgetting Service Registration
+-------------------------------
+
+When the AI creates a new service class, it sometimes forgets to register it in the DI container. If you get "Service not found" errors, ask:
+
+```
+What changes do I need in services.neon for the new OrderExportService?
+```
+
+
+Asking for Too Much at Once
+---------------------------
+
+While AI can handle complex tasks, sometimes it helps to break them down:
+
+**Too ambitious:**
+
+```
+Build me a complete e-commerce system with product catalog,
+shopping cart, checkout, payments, order tracking, and admin panel.
+```
+
+**Better approach:**
+
+```
+Let's build an e-commerce system step by step. Start with the product
+catalog – I need to list, view, and admin products.
+```
+
+
+When AI Excels (and When It Doesn't)
+====================================
+
+
+AI is Great For
+---------------
+
+- **Boilerplate code** – Presenters, forms, entities, basic templates
+- **Following patterns** – "Do it like X but for Y"
+- **Understanding code** – "What does this method do?"
+- **Generating tests** – Given implementation, create tests
+- **Refactoring** – Improving code structure while keeping behavior
+
+
+Consider Manual Coding For
+--------------------------
+
+- **Complex business logic** – Domain rules that require careful thinking
+- **Performance-critical code** – Algorithms that need optimization
+- **Security-sensitive code** – Authentication, authorization, encryption
+- **Novel solutions** – Things that don't follow existing patterns
+
+AI is a multiplier, not a replacement. It makes good developers faster, but it still needs a good developer guiding it.
+
+
+Final Thoughts
+==============
+
+The best way to learn AI-assisted development is to practice. Start with simple tasks, pay attention to what works, and gradually take on more complex projects.
+
+And remember: the AI is your assistant. You're still the developer. You make the decisions, you review the code, and you're responsible for the quality of the final product.
+
+Happy coding!
diff --git a/ai/meta.json b/ai/meta.json
new file mode 100644
index 0000000000..0967ef424b
--- /dev/null
+++ b/ai/meta.json
@@ -0,0 +1 @@
+{}
diff --git a/application/bg/@meta.texy b/application/bg/@meta.texy
new file mode 100644
index 0000000000..57804a1127
--- /dev/null
+++ b/application/bg/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация на Nette}}
diff --git a/application/bg/routing.texy b/application/bg/routing.texy
index f6d0f09e15..d3a66e32fa 100644
--- a/application/bg/routing.texy
+++ b/application/bg/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/cs/@meta.texy b/application/cs/@meta.texy
new file mode 100644
index 0000000000..462d9add80
--- /dev/null
+++ b/application/cs/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentace}}
diff --git a/application/cs/ajax.texy b/application/cs/ajax.texy
index fd274408d1..fe7772083f 100644
--- a/application/cs/ajax.texy
+++ b/application/cs/ajax.texy
@@ -247,3 +247,9 @@ public function handleFoo(int $bar): void
{
}
```
+
+
+Další četba
+===========
+
+- [Dynamické snippety |best-practices:dynamic-snippets]
diff --git a/application/cs/components.texy b/application/cs/components.texy
index 43a7f0f72b..7d433ab890 100644
--- a/application/cs/components.texy
+++ b/application/cs/components.texy
@@ -422,10 +422,10 @@ Nette\ComponentModel\Component { IComponent }
```
-Životní cyklus componenty
+Životní cyklus komponenty
-------------------------
-[* lifecycle-component.svg *] *** *Životní cyklus componenty* .<>
+[* lifecycle-component.svg *] *** *Životní cyklus komponenty* .<>
Validace persistentních parametrů
diff --git a/application/cs/creating-links.texy b/application/cs/creating-links.texy
index 0263cbbc4a..8658cb3646 100644
--- a/application/cs/creating-links.texy
+++ b/application/cs/creating-links.texy
@@ -12,7 +12,7 @@ Tvořit odkazy v Nette je jednoduché, jako ukazovat prstem. Stačí jen namíř
-Díky [obousměrnému routování |routing] nebudete nikdy muset do šablon či kódu zapisovat navrdo URL adresy vaší aplikace, které se mohou později měnit, nebo je komplikovaně skládat. V odkazu stačí uvést presenter a akci, předat případné parametry a framework už URL vygeneruje sám. Vlastně je to velice podobné, jako když voláte funkci. To se vám bude líbit.
+Díky [obousměrnému routování |routing] nebudete nikdy muset do šablon či kódu zapisovat natvrdo URL adresy vaší aplikace, které se mohou později měnit, nebo je komplikovaně skládat. V odkazu stačí uvést presenter a akci, předat případné parametry a framework už URL vygeneruje sám. Vlastně je to velice podobné, jako když voláte funkci. To se vám bude líbit.
V šabloně presenteru
@@ -130,6 +130,8 @@ Odkazy generované pomocí `link()` nebo `n:href` jsou vždy absolutní cesty (t
Pro vygenerování absolutní URL přidejte na začátek dvě lomítka (např. `n:href="//Home:"`). Nebo lze přepnout presenter, aby generoval jen absolutní odkazy nastavením `$this->absoluteUrls = true`.
+V šabloně lze také použít filtr `|absoluteUrl`, který relativní cestu převede na absolutní.
+
Odkaz na aktuální stránku
=========================
@@ -179,6 +181,21 @@ Pro zjištění, zda jsme v určitém modulu nebo jeho submodulu, použijeme met
```
+Změna základu pro odkazy .{data-version:v3.2.7}
+===============================================
+
+Ve výchozím stavu se relativní odkazy odvíjejí od aktuálního presenteru. To lze změnit pomocí `{linkBase}`:
+
+```latte
+{linkBase Admin:Dashboard}
+detail produktu
+```
+
+Odkaz povede na `Admin:Dashboard:Product:show`. Ovlivněny jsou pouze relativní odkazy - absolutní odkazy začínající dvojtečkou a odkazy na aktuální presenter (`this`, `show`) zůstávají nezměněny.
+
+`{linkBase}` platí pro celou šablonu a je užitečné zejména v šablonách layoutu, kde zajistí konzistentní odkazy nezávisle na volajícím presenteru.
+
+
Odkazy na signál
================
diff --git a/application/cs/presenters.texy b/application/cs/presenters.texy
index 368fc7ceda..04cd942e32 100644
--- a/application/cs/presenters.texy
+++ b/application/cs/presenters.texy
@@ -122,6 +122,8 @@ Kdykoliv během životního cyklu můžeme některou z následujících metod od
- `sendResponse($response)` presenter ukončí a odešle [vlastní odpověď |#Odpovědi]
- `terminate()` presenter ukončí bez odpovědi
+Každá z těchto metod okamžitě ukončí činnost presenteru vyhozením tzv. tiché ukončovací výjimky `Nette\Application\AbortException`.
+
Pokud žádnou z těchto metod nezavoláte, presenter automaticky přistoupí k vykreslí šablony. Proč? Protože v 99 % případů chceme vykreslit šablonu, tudíž presenter tohle chování bere jako výchozí a chce nám ulehčit práci.
@@ -491,6 +493,14 @@ class MyPresenter extends Nette\Application\UI\Presenter
Je důležité zdůraznit, že pokud povolíte metodu `OPTIONS`, musíte ji následně také patřičně obsloužit v rámci svého presenteru. Metoda je často používána jako tzv. preflight request, který prohlížeč automaticky odesílá před skutečným požadavkem, když je potřeba zjistit, zda je požadavek povolený z hlediska CORS (Cross-Origin Resource Sharing) politiky. Pokud metodu povolíte, ale neimplementujete správnou odpověď, může to vést k nekonzistencím a potenciálním bezpečnostním problémům.
+Označení zastaralých akcí .{data-version:3.2.3}
+-----------------------------------------------
+
+Atribut `#[Deprecated]` slouží k označení akcí, signálů nebo celých presenterů, které jsou zastaralé a měly by být v budoucnu odstraněny. Při generování odkazů na takto označené části aplikace Nette vyhodí varování, které vývojáře upozorní.
+
+Atribut lze aplikovat jak na celou třídu presenteru, tak na jednotlivé metody `action()`, `render()` a `handle()`.
+
+
Další četba
===========
diff --git a/application/cs/routing.texy b/application/cs/routing.texy
index 826bed4363..3a2e753731 100644
--- a/application/cs/routing.texy
+++ b/application/cs/routing.texy
@@ -306,7 +306,7 @@ Parametry `presenter`, `action` a `module` už mají předdefinované filtry, kt
Obecné filtry
-------------
-Vedle filtrů určených pro konkrétní parametry můžeme definovat též obecné filtry, které obdrží asociativní pole všech parametrů, které mohou jakkoliv modifikovat a poté je vrátí. Obecné filtry definujeme pod klíčem `null`.
+Vedle filtrů určených pro konkrétní parametry můžeme definovat též obecné filtry, které obdrží asociativní pole všech parametrů, které mohou jakkoliv modifikovat a poté je vrátí. Obecné filtry definujeme pod prázdným klíčem.
```php
use Nette\Routing\Route;
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/cs/templates.texy b/application/cs/templates.texy
index 4ded503e34..5e4452a586 100644
--- a/application/cs/templates.texy
+++ b/application/cs/templates.texy
@@ -114,15 +114,48 @@ Soubory, kde se dohledávají šablony layoutu, lze změnit překrytím metody [
Proměnné v šabloně
------------------
-Proměnné do šablony předáváme tak, že je zapíšeme do `$this->template` a potom je máme k dispozici v šabloně jako lokální proměnné:
+Proměnné do šablony předáváme zápisem do `$this->template`. V šabloně jsou pak dostupné jako lokální proměnné:
```php
$this->template->article = $this->articles->getById($id);
```
-Takto jednoduše můžeme do šablon předat jakékoliv proměnné. Při vývoji robustních aplikací ale bývá užitečnější se omezit. Například tak, že explicitně nadefinujeme výčet proměnných, které šablona očekává, a jejich typů. Díky tomu nám bude moci PHP kontrolovat typy, IDE správně našeptávat a statická analýza odhalovat chyby.
+Pokud chcete, aby se hodnota určité property automaticky předala do šablony jako proměnná, označte ji atributem `#[TemplateVariable]` a viditelností public nebo protected: .{data-version:3.2.9}
-A jak takový výčet nadefinujeme? Jednoduše v podobě třídy a její properties. Pojmenujeme ji podobně jako presenter, jen s `Template` na konci:
+```php
+use Nette\Application\Attributes\TemplateVariable;
+
+class ArticlePresenter extends Nette\Application\UI\Presenter
+{
+ #[TemplateVariable]
+ public string $siteName = 'Můj blog';
+}
+```
+
+Pokud do šablony vložíte proměnnou se stejným názvem, `#[TemplateVariable]` ji nepřepíše.
+
+
+Výchozí proměnné
+----------------
+
+Presentery a komponenty předávají do šablon několik užitečných proměnných automaticky:
+
+- `$basePath` je absolutní URL cesta ke kořenovému adresáři (např. `/eshop`)
+- `$baseUrl` je absolutní URL ke kořenovému adresáři (např. `http://localhost/eshop`)
+- `$user` je objekt [reprezentující uživatele |security:authentication]
+- `$presenter` je aktuální presenter
+- `$control` je aktuální komponenta nebo presenter
+- `$flashes` pole [zpráv |presenters#Flash zprávy] zaslaných funkcí `flashMessage()`
+
+Pokud používáte vlastní třídu šablony, tyto proměnné se předají, pokud pro ně vytvoříte property.
+
+
+Typově bezpečné šablony
+-----------------------
+
+Při vývoji robustních aplikací je užitečné explicitně nadefinovat, jaké proměnné šablona očekává a jakého jsou typu. Získáte tak typovou kontrolu v PHP, chytré našeptávání v IDE a schopnost statické analýzy odhalovat chyby.
+
+Jak takový výčet nadefinovat? Jednoduše v podobě třídy s properties reprezentujícími proměnné šablony. Pojmenujeme ji podobně jako presenter, jen s `Template` na konci:
```php
/**
@@ -141,22 +174,22 @@ class ArticleTemplate extends Nette\Bridges\ApplicationLatte\Template
}
```
-Objekt `$this->template` v presenteru bude nyní instancí třídy `ArticleTemplate`. Takže PHP bude při zápisu kontrolovat deklarované typy. A počínaje verzí PHP 8.2 upozorní i na zápis do neexistující proměnné, v předchozích verzích lze téhož dosáhnout použitím traity [Nette\SmartObject |utils:smartobject].
+Objekt `$this->template` v presenteru bude nyní instancí třídy `ArticleTemplate`. PHP tak bude při zápisu kontrolovat deklarované typy.
-Anotace `@property-read` je určená pro IDE a statickou analýzu, díky ní bude fungovat našeptávání, viz "PhpStorm and code completion for $this->template":https://blog.nette.org/en/phpstorm-and-code-completion-for-this-template.
+Anotace `@property-read` slouží pro IDE a statickou analýzu, díky ní bude fungovat našeptávání, viz "PhpStorm and code completion for $this->template":https://blog.nette.org/en/phpstorm-and-code-completion-for-this-template.
[* phpstorm-completion.webp *]
-Luxusu našeptávání si můžete dopřát i v šablonách, stačí do PhpStorm nainstalovat plugin pro Latte a uvést na začátek šablony název třídy, více v článku "Latte: jak na typový systém":https://blog.nette.org/cs/latte-jak-na-typovy-system:
+Našeptávání můžete využít i přímo v šablonách. Stačí do PhpStorm nainstalovat plugin pro Latte a uvést na začátek šablony název třídy parametrů šablony, více v článku "Latte: jak na typový systém":https://blog.nette.org/cs/latte-jak-na-typovy-system:
```latte
{templateType App\Presentation\Article\ArticleTemplate}
...
```
-Takto fungují i šablony v komponentách, stačí jen dodržet jmennou konvenci a pro komponentu např. `FifteenControl` vytvořit třídu šablony `FifteenTemplate`.
+Totéž platí i pro komponenty. Stačí dodržet jmennou konvenci a pro komponentu např. `FifteenControl` vytvořit třídu parametrů `FifteenTemplate`.
-Pokud potřebujete vytvořit `$template` jako instanci jiné třídy, využijte metodu `createTemplate()`:
+Pokud potřebujete použít jinou třídu parametrů, využijte metodu `createTemplate()`:
```php
public function renderDefault(): void
@@ -169,21 +202,6 @@ public function renderDefault(): void
```
-Výchozí proměnné
-----------------
-
-Presentery a komponenty předávají do šablon několik užitečných proměnných automaticky:
-
-- `$basePath` je absolutní URL cesta ke kořenovému adresáři (např. `/eshop`)
-- `$baseUrl` je absolutní URL ke kořenovému adresáři (např. `http://localhost/eshop`)
-- `$user` je objekt [reprezentující uživatele |security:authentication]
-- `$presenter` je aktuální presenter
-- `$control` je aktuální komponenta nebo presenter
-- `$flashes` pole [zpráv |presenters#Flash zprávy] zaslaných funkcí `flashMessage()`
-
-Pokud používáte vlastní třídu šablony, tyto proměnné se předají, pokud pro ně vytvoříte property.
-
-
Vytváření odkazů
----------------
@@ -205,21 +223,67 @@ Více informací najdete v kapitole [Vytváření odkazů URL|creating-links].
Vlastní filtry, značky apod.
----------------------------
-Šablonovací systém Latte lze rozšířit o vlastní filtry, funkce, značky apod. Lze tak učinit přímo v metodě `render` nebo `beforeRender()`:
+Šablonovací systém Latte lze rozšířit o vlastní filtry, funkce, značky a další prvky. K dispozici jsou tři způsoby, jak to udělat, od nejrychlejších ad-hoc řešení až po architektonický přístup pro celou aplikaci.
+
+**Ad-hoc v metodách presenteru**
+
+Nejrychlejší způsob je přidat filtr nebo funkci přímo v kódu presenteru či komponenty. V presenteru je k tomu vhodná metoda `beforeRender()` nebo `render()`:
```php
-public function beforeRender(): void
+protected function beforeRender(): void
{
// přidání filtru
- $this->template->addFilter('foo', /* ... */);
+ $this->template->addFilter('money', fn($val) => round($val) . ' Kč');
+
+ // přidání funkce
+ $this->template->addFunction('isWeekend', fn($date) => $date->format('N') >= 6);
+}
+```
+
+V šabloně pak:
- // nebo konfigurujeme přímo objekt Latte\Engine
+```latte
+Cena: {$price|money}
+
+{if isWeekend($now)} ... {/if}
+```
+
+Pro složitější logiku můžete konfigurovat přímo objekt `Latte\Engine`:
+
+```php
+protected function beforeRender(): void
+{
$latte = $this->template->getLatte();
- $latte->addFilterLoader(/* ... */);
+ $latte->setFeature(Latte\Feature::MigrationWarnings);
+}
+```
+
+**Pomocí atributů**
+
+Elegantní způsob je definovat filtry a funkce jako metody přímo ve [třídě parametrů šablony|#Typově bezpečné šablony] presenteru nebo komponenty a označit je atributy:
+
+```php
+class ArticleTemplate extends Nette\Bridges\ApplicationLatte\Template
+{
+ #[Latte\Attributes\TemplateFilter]
+ public function money(float $val): string
+ {
+ return round($val) . ' Kč';
+ }
+
+ #[Latte\Attributes\TemplateFunction]
+ public function isWeekend(DateTimeInterface $date): bool
+ {
+ return $date->format('N') >= 6;
+ }
}
```
-Latte ve verzi 3 nabízí pokročilejší způsob a to vytvoření si [extension |latte:extending-latte#Latte Extension] pro každý webový projekt. Kusý příklad takové třídy:
+Latte automaticky rozpozná a zaregistruje metody označené těmito atributy. Název filtru nebo funkce v šabloně odpovídá názvu metody. Tyto metody nesmí být privátní.
+
+**Globálně pomocí Extension**
+
+Předchozí způsoby jsou vhodné pro filtry a funkce, které potřebujete jen v konkrétním presenteru nebo komponentě, nikoliv v celé aplikaci. Pro celou aplikaci je nejvhodnější vytvořit si [extension |latte:extending-latte#Latte Extension]. Jde o třídu, která centralizuje všechna rozšíření Latte pro celý projekt. Kusý příklad:
```php
namespace App\Presentation\Accessory;
@@ -251,11 +315,16 @@ final class LatteExtension extends Latte\Extension
];
}
+ private function filterTimeAgoInWords(DateTimeInterface $time): string
+ {
+ // ...
+ }
+
// ...
}
```
-Zaregistrujeme ji pomocí [konfigurace |configuration#Šablony Latte]:
+Extension zaregistrujeme pomocí [konfigurace |configuration#Šablony Latte]:
```neon
latte:
@@ -263,6 +332,8 @@ latte:
- App\Presentation\Accessory\LatteExtension
```
+Výhodou extension je, že lze využít dependency injection, mít přístup k modelové vrstvě aplikace a všechna rozšíření mít přehledně na jednom místě. Extension umožnuje definovat i vlastní značky, providery, průchody pro Latte kompilátor a další.
+
Překládání
----------
diff --git a/application/de/@meta.texy b/application/de/@meta.texy
new file mode 100644
index 0000000000..b3b806b2ca
--- /dev/null
+++ b/application/de/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentation}}
diff --git a/application/de/routing.texy b/application/de/routing.texy
index 251247119d..ff2f7378e0 100644
--- a/application/de/routing.texy
+++ b/application/de/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/el/@meta.texy b/application/el/@meta.texy
new file mode 100644
index 0000000000..88e29852c7
--- /dev/null
+++ b/application/el/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Τεκμηρίωση}}
diff --git a/application/el/routing.texy b/application/el/routing.texy
index 4886294f8b..31800ef023 100644
--- a/application/el/routing.texy
+++ b/application/el/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/en/@meta.texy b/application/en/@meta.texy
new file mode 100644
index 0000000000..42471908b0
--- /dev/null
+++ b/application/en/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentation}}
diff --git a/application/en/ajax.texy b/application/en/ajax.texy
index 21a4475c2a..b65ca6adce 100644
--- a/application/en/ajax.texy
+++ b/application/en/ajax.texy
@@ -247,3 +247,9 @@ public function handleFoo(int $bar): void
{
}
```
+
+
+Further Reading
+===============
+
+- [Dynamic Snippets |best-practices:dynamic-snippets]
diff --git a/application/en/creating-links.texy b/application/en/creating-links.texy
index 45ec9bd73e..f831b5e018 100644
--- a/application/en/creating-links.texy
+++ b/application/en/creating-links.texy
@@ -130,6 +130,8 @@ Links generated using `link()` or `n:href` are always absolute paths (i.e., they
To generate an absolute URL, add two slashes at the beginning (e.g., `n:href="//Home:"`). Alternatively, you can switch the presenter to generate only absolute links by setting `$this->absoluteUrls = true`.
+The `|absoluteUrl` filter can also be used in the template to convert a relative path to an absolute path.
+
Link to Current Page
====================
@@ -179,6 +181,21 @@ To determine if we are in a specific module or its submodule, use the `isModuleC
```
+Changing Link Base .{data-version:v3.2.7}
+=========================================
+
+By default, relative links are derived from the current presenter. This can be changed using `{linkBase}`:
+
+```latte
+{linkBase Admin:Dashboard}
+product detail
+```
+
+The link will lead to `Admin:Dashboard:Product:show`. Only relative links are affected - absolute links starting with a colon and links to the current presenter (`this`, `show`) remain unchanged.
+
+`{linkBase}` applies to the entire template and is especially useful in layout templates, where it ensures consistent links regardless of the calling presenter.
+
+
Links to Signal
===============
diff --git a/application/en/presenters.texy b/application/en/presenters.texy
index 3d36da3b2c..7658686bbf 100644
--- a/application/en/presenters.texy
+++ b/application/en/presenters.texy
@@ -122,6 +122,8 @@ At any point during the life cycle, we can use one of the following methods to s
- `sendResponse($response)` terminates the presenter and sends a [custom response |#Responses]
- `terminate()` terminates the presenter without a response
+Each of these methods immediately terminates the presenter by throwing a silent termination exception `Nette\Application\AbortException`.
+
If you don't call any of these methods, the presenter automatically proceeds to render the template. Why? Because in 99% of cases, we want to render a template, so the presenter adopts this behavior as the default to simplify our work.
@@ -491,6 +493,14 @@ class MyPresenter extends Nette\Application\UI\Presenter
It's important to emphasize that if you enable the `OPTIONS` method, you must subsequently handle it appropriately within your presenter. This method is often used as a so-called preflight request, which the browser automatically sends before the actual request when it's necessary to determine if the request is permissible according to the CORS (Cross-Origin Resource Sharing) policy. If you enable the method but don't implement the correct response, it can lead to inconsistencies and potential security problems.
+Marking Deprecated Actions .{data-version:3.2.3}
+------------------------------------------------
+
+The `#[Deprecated]` attribute marks actions, signals, or entire presenters as deprecated and scheduled for future removal. When generating links to deprecated parts of the application, Nette throws a warning to alert developers.
+
+You can apply the attribute to either the entire presenter class or to individual `action()`, `render()`, and `handle()` methods.
+
+
Further Reading
===============
diff --git a/application/en/routing.texy b/application/en/routing.texy
index daa1c181d8..4b83f317f2 100644
--- a/application/en/routing.texy
+++ b/application/en/routing.texy
@@ -306,7 +306,7 @@ The parameters `presenter`, `action`, and `module` already have predefined filte
General Filters
---------------
-Besides filters intended for specific parameters, we can also define general filters that receive an associative array of all parameters, which they can modify in any way and then return. General filters are defined under the key `null`.
+Besides filters intended for specific parameters, we can also define general filters that receive an associative array of all parameters, which they can modify in any way and then return. General filters are defined under the empty key.
```php
use Nette\Routing\Route;
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/en/templates.texy b/application/en/templates.texy
index 2950a8f35c..c5de1f1484 100644
--- a/application/en/templates.texy
+++ b/application/en/templates.texy
@@ -111,18 +111,51 @@ Using `$this->setLayout(false)` or the `{layout none}` tag inside the template d
The files where layout templates are looked up can be changed by overriding the [formatLayoutTemplateFiles() |api:Nette\Application\UI\Presenter::formatLayoutTemplateFiles()] method, which returns an array of possible file names.
-Variables in the Template
--------------------------
+Template Variables
+------------------
-Variables are passed to the template by writing them to `$this->template`, and then they are available in the template as local variables:
+Variables are passed to templates by writing them to `$this->template`. They then become available in the template as local variables:
```php
$this->template->article = $this->articles->getById($id);
```
-This way, we can easily pass any variables to templates. However, when developing robust applications, it is often more useful to impose limitations. For example, by explicitly defining a list of variables that the template expects and their types. This allows PHP to perform type checking, the IDE to provide correct autocompletion, and static analysis to detect errors.
+To automatically pass a property value to the template as a variable, mark it with the `#[TemplateVariable]` attribute and public or protected visibility: .{data-version:3.2.9}
-And how do we define such a list? Simply in the form of a class and its properties. We name it similarly to the presenter, but with `Template` at the end:
+```php
+use Nette\Application\Attributes\TemplateVariable;
+
+class ArticlePresenter extends Nette\Application\UI\Presenter
+{
+ #[TemplateVariable]
+ public string $siteName = 'My blog';
+}
+```
+
+If you pass a variable with the same name to the template, `#[TemplateVariable]` won’t override it.
+
+
+Default Variables
+-----------------
+
+Presenters and components automatically pass several useful variables to templates:
+
+- `$basePath` is the absolute URL path to the root directory (e.g., `/eshop`)
+- `$baseUrl` is the absolute URL to the root directory (e.g., `http://localhost/eshop`)
+- `$user` is an object [representing the user |security:authentication]
+- `$presenter` is the current presenter
+- `$control` is the current component or presenter
+- `$flashes` is an array of [messages |presenters#Flash Messages] sent by the `flashMessage()` function
+
+If you use a custom template class, these variables are passed if you create a property for them.
+
+
+Type-Safe Templates
+-------------------
+
+When developing robust applications, it's useful to explicitly define which variables the template expects and their types. This provides type checking in PHP, smart hints in your IDE, and enables static analysis to catch errors.
+
+How do you define such a list? Simply as a class with properties representing template variables. Name it similarly to the presenter, just with `Template` at the end:
```php
/**
@@ -141,22 +174,22 @@ class ArticleTemplate extends Nette\Bridges\ApplicationLatte\Template
}
```
-The `$this->template` object in the presenter will now be an instance of the `ArticleTemplate` class. So PHP will check the declared types upon writing. And starting from PHP 8.2, it will also warn about writing to a non-existent variable; in previous versions, the same can be achieved using the [Nette\SmartObject |utils:smartobject] trait.
+The `$this->template` object in the presenter will now be an instance of the `ArticleTemplate` class. PHP will thus check the declared types when writing.
-The `@property-read` annotation is intended for IDEs and static analysis; thanks to it, autocompletion will work, see "PhpStorm and code completion for $this->template":https://blog.nette.org/en/phpstorm-and-code-completion-for-this-template.
+The `@property-read` annotation is for the IDE and static analysis, enabling code completion, see "PhpStorm and code completion for $this->template":https://blog.nette.org/en/phpstorm-and-code-completion-for-this-template.
[* phpstorm-completion.webp *]
-You can enjoy the luxury of autocompletion in templates too; just install the Latte plugin for PhpStorm and specify the class name at the beginning of the template, more in the article "Latte: How to Use Type System":https://blog.nette.org/en/latte-how-to-use-type-system:
+You can also use code completion directly in templates. Just install the Latte plugin for PhpStorm and specify the template parameter class name at the beginning of the template, more in the article "Latte: how to use the type system":https://blog.nette.org/en/latte-how-to-use-type-system:
```latte
{templateType App\Presentation\Article\ArticleTemplate}
...
```
-This is also how templates work in components; just follow the naming convention and create a template class `FifteenTemplate` for a component like `FifteenControl`.
+The same applies to components. Just follow the naming convention and create a parameter class `FifteenTemplate` for a component like `FifteenControl`.
-If you need to create `$template` as an instance of another class, use the `createTemplate()` method:
+If you need to use a different parameter class, use the `createTemplate()` method:
```php
public function renderDefault(): void
@@ -169,21 +202,6 @@ public function renderDefault(): void
```
-Default Variables
------------------
-
-Presenters and components automatically pass several useful variables to templates:
-
-- `$basePath` is the absolute URL path to the root directory (e.g., `/eshop`)
-- `$baseUrl` is the absolute URL to the root directory (e.g., `http://localhost/eshop`)
-- `$user` is an object [representing the user |security:authentication]
-- `$presenter` is the current presenter
-- `$control` is the current component or presenter
-- `$flashes` is an array of [messages |presenters#Flash Messages] sent by the `flashMessage()` function
-
-If you use a custom template class, these variables are passed if you create a property for them.
-
-
Creating Links
--------------
@@ -205,21 +223,67 @@ More information can be found in the chapter [Creating URL Links|creating-links]
Custom Filters, Tags, etc.
--------------------------
-The Latte templating system can be extended with custom filters, functions, tags, etc. This can be done directly in the `render` or `beforeRender()` method:
+The Latte templating system can be extended with custom filters, functions, tags, and other elements. There are three approaches available, ranging from quick ad-hoc solutions to architectural patterns for entire applications.
+
+**Ad-hoc in Presenter Methods**
+
+The quickest approach is adding filters or functions directly in presenter or component code. In presenters, the `beforeRender()` or `render()` methods work well for this:
```php
-public function beforeRender(): void
+protected function beforeRender(): void
{
// adding a filter
- $this->template->addFilter('foo', /* ... */);
+ $this->template->addFilter('money', fn($val) => '$' . number_format($val, 2));
+
+ // adding a function
+ $this->template->addFunction('isWeekend', fn($date) => $date->format('N') >= 6);
+}
+```
+
+In the template:
- // or configure the Latte\Engine object directly
+```latte
+Price: {$price|money}
+
+{if isWeekend($now)} ... {/if}
+```
+
+For more complex logic, you can configure the `Latte\Engine` object directly:
+
+```php
+protected function beforeRender(): void
+{
$latte = $this->template->getLatte();
- $latte->addFilterLoader(/* ... */);
+ $latte->setFeature(Latte\Feature::MigrationWarnings);
+}
+```
+
+**Using Attributes**
+
+A more elegant approach is defining filters and functions as methods directly in the presenter or component's [template parameter class|#Type-safe templates], marked with attributes:
+
+```php
+class ArticleTemplate extends Nette\Bridges\ApplicationLatte\Template
+{
+ #[Latte\Attributes\TemplateFilter]
+ public function money(float $val): string
+ {
+ return '$' . number_format($val, 2);
+ }
+
+ #[Latte\Attributes\TemplateFunction]
+ public function isWeekend(DateTimeInterface $date): bool
+ {
+ return $date->format('N') >= 6;
+ }
}
```
-Latte version 3 offers a more advanced way by creating an [extension |latte:extending-latte#Latte Extension] for each web project. Here is a brief example of such a class:
+Latte automatically discovers and registers methods marked with these attributes. The filter or function name in templates matches the method name. These methods must not be private.
+
+**Globally Using Extensions**
+
+The previous approaches suit filters and functions needed only in specific presenters or components, not application-wide. For the entire application, creating an [extension |latte:extending-latte#Latte Extension] works best. This class centralizes all Latte extensions for your project. A brief example:
```php
namespace App\Presentation\Accessory;
@@ -251,11 +315,16 @@ final class LatteExtension extends Latte\Extension
];
}
+ private function filterTimeAgoInWords(DateTimeInterface $time): string
+ {
+ // ...
+ }
+
// ...
}
```
-We register it using [configuration |configuration#Latte Templates]:
+Register the extension through [configuration |configuration#Latte Templates]:
```neon
latte:
@@ -263,6 +332,8 @@ latte:
- App\Presentation\Accessory\LatteExtension
```
+Extensions offer several advantages: dependency injection support, access to your application's model layer, and centralized management of all extensions. They also support custom tags, providers, compiler passes, and more.
+
Translating
-----------
diff --git a/application/es/@meta.texy b/application/es/@meta.texy
new file mode 100644
index 0000000000..1670b124ad
--- /dev/null
+++ b/application/es/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentación}}
diff --git a/application/es/routing.texy b/application/es/routing.texy
index 829edb3c7d..d906f83f48 100644
--- a/application/es/routing.texy
+++ b/application/es/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/fr/@meta.texy b/application/fr/@meta.texy
new file mode 100644
index 0000000000..72ae4b8db8
--- /dev/null
+++ b/application/fr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentation Nette}}
diff --git a/application/fr/routing.texy b/application/fr/routing.texy
index 41a575cac4..66bfebc31b 100644
--- a/application/fr/routing.texy
+++ b/application/fr/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/hu/@meta.texy b/application/hu/@meta.texy
new file mode 100644
index 0000000000..c172d1cda5
--- /dev/null
+++ b/application/hu/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette dokumentáció}}
diff --git a/application/hu/routing.texy b/application/hu/routing.texy
index 0887f12764..4fb937eba5 100644
--- a/application/hu/routing.texy
+++ b/application/hu/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/it/@meta.texy b/application/it/@meta.texy
new file mode 100644
index 0000000000..4647d0c8a2
--- /dev/null
+++ b/application/it/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentazione Nette}}
diff --git a/application/it/routing.texy b/application/it/routing.texy
index c308d57f62..36b8f5968c 100644
--- a/application/it/routing.texy
+++ b/application/it/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/ja/@meta.texy b/application/ja/@meta.texy
new file mode 100644
index 0000000000..d3c41dc3d7
--- /dev/null
+++ b/application/ja/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette ドキュメンテーション}}
diff --git a/application/ja/routing.texy b/application/ja/routing.texy
index d3c524f7ab..4dd36be16c 100644
--- a/application/ja/routing.texy
+++ b/application/ja/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/pl/@meta.texy b/application/pl/@meta.texy
new file mode 100644
index 0000000000..61ac92d1af
--- /dev/null
+++ b/application/pl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Dokumentacja Nette}}
diff --git a/application/pl/routing.texy b/application/pl/routing.texy
index 49f68aa093..34577ae078 100644
--- a/application/pl/routing.texy
+++ b/application/pl/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/pt/@meta.texy b/application/pt/@meta.texy
new file mode 100644
index 0000000000..41a853b6aa
--- /dev/null
+++ b/application/pt/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentação Nette}}
diff --git a/application/pt/routing.texy b/application/pt/routing.texy
index 659307ca93..6becfb0d3b 100644
--- a/application/pt/routing.texy
+++ b/application/pt/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/ro/@meta.texy b/application/ro/@meta.texy
new file mode 100644
index 0000000000..9c744b37d6
--- /dev/null
+++ b/application/ro/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentație Nette}}
diff --git a/application/ro/routing.texy b/application/ro/routing.texy
index e0b8840500..0d580d0565 100644
--- a/application/ro/routing.texy
+++ b/application/ro/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/ru/@meta.texy b/application/ru/@meta.texy
new file mode 100644
index 0000000000..7f329adfce
--- /dev/null
+++ b/application/ru/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация Nette}}
diff --git a/application/ru/routing.texy b/application/ru/routing.texy
index dbe0c6a228..4e2896a131 100644
--- a/application/ru/routing.texy
+++ b/application/ru/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/sl/@meta.texy b/application/sl/@meta.texy
new file mode 100644
index 0000000000..724324bee5
--- /dev/null
+++ b/application/sl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentacija}}
diff --git a/application/sl/routing.texy b/application/sl/routing.texy
index dbdd549664..06c2ccee69 100644
--- a/application/sl/routing.texy
+++ b/application/sl/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/tr/@meta.texy b/application/tr/@meta.texy
new file mode 100644
index 0000000000..8dfe82f311
--- /dev/null
+++ b/application/tr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokümantasyonu}}
diff --git a/application/tr/routing.texy b/application/tr/routing.texy
index 5b0b81e30a..8fccd6c0b1 100644
--- a/application/tr/routing.texy
+++ b/application/tr/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/application/uk/@meta.texy b/application/uk/@meta.texy
new file mode 100644
index 0000000000..96e2d9752a
--- /dev/null
+++ b/application/uk/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документація Nette}}
diff --git a/application/uk/routing.texy b/application/uk/routing.texy
index a9db693215..ab3b132ccd 100644
--- a/application/uk/routing.texy
+++ b/application/uk/routing.texy
@@ -314,7 +314,7 @@ use Nette\Routing\Route;
$router->addRoute('/', [
'presenter' => 'Home',
'action' => 'default',
- null => [
+ '' => [
Route::FilterIn => function (array $params): array { /* ... */ },
Route::FilterOut => function (array $params): array { /* ... */ },
],
diff --git a/assets/bg/@meta.texy b/assets/bg/@meta.texy
new file mode 100644
index 0000000000..57804a1127
--- /dev/null
+++ b/assets/bg/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация на Nette}}
diff --git a/assets/cs/@meta.texy b/assets/cs/@meta.texy
new file mode 100644
index 0000000000..462d9add80
--- /dev/null
+++ b/assets/cs/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentace}}
diff --git a/assets/de/@meta.texy b/assets/de/@meta.texy
new file mode 100644
index 0000000000..b3b806b2ca
--- /dev/null
+++ b/assets/de/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentation}}
diff --git a/assets/el/@meta.texy b/assets/el/@meta.texy
new file mode 100644
index 0000000000..88e29852c7
--- /dev/null
+++ b/assets/el/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Τεκμηρίωση}}
diff --git a/assets/en/@meta.texy b/assets/en/@meta.texy
new file mode 100644
index 0000000000..42471908b0
--- /dev/null
+++ b/assets/en/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentation}}
diff --git a/assets/es/@meta.texy b/assets/es/@meta.texy
new file mode 100644
index 0000000000..1670b124ad
--- /dev/null
+++ b/assets/es/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentación}}
diff --git a/assets/fr/@meta.texy b/assets/fr/@meta.texy
new file mode 100644
index 0000000000..72ae4b8db8
--- /dev/null
+++ b/assets/fr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentation Nette}}
diff --git a/assets/hu/@meta.texy b/assets/hu/@meta.texy
new file mode 100644
index 0000000000..c172d1cda5
--- /dev/null
+++ b/assets/hu/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette dokumentáció}}
diff --git a/assets/it/@meta.texy b/assets/it/@meta.texy
new file mode 100644
index 0000000000..4647d0c8a2
--- /dev/null
+++ b/assets/it/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentazione Nette}}
diff --git a/assets/ja/@meta.texy b/assets/ja/@meta.texy
new file mode 100644
index 0000000000..d3c41dc3d7
--- /dev/null
+++ b/assets/ja/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette ドキュメンテーション}}
diff --git a/assets/pl/@meta.texy b/assets/pl/@meta.texy
new file mode 100644
index 0000000000..61ac92d1af
--- /dev/null
+++ b/assets/pl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Dokumentacja Nette}}
diff --git a/assets/pt/@meta.texy b/assets/pt/@meta.texy
new file mode 100644
index 0000000000..41a853b6aa
--- /dev/null
+++ b/assets/pt/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentação Nette}}
diff --git a/assets/ro/@meta.texy b/assets/ro/@meta.texy
new file mode 100644
index 0000000000..9c744b37d6
--- /dev/null
+++ b/assets/ro/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentație Nette}}
diff --git a/assets/ru/@meta.texy b/assets/ru/@meta.texy
new file mode 100644
index 0000000000..7f329adfce
--- /dev/null
+++ b/assets/ru/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация Nette}}
diff --git a/assets/sl/@meta.texy b/assets/sl/@meta.texy
new file mode 100644
index 0000000000..724324bee5
--- /dev/null
+++ b/assets/sl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentacija}}
diff --git a/assets/tr/@meta.texy b/assets/tr/@meta.texy
new file mode 100644
index 0000000000..8dfe82f311
--- /dev/null
+++ b/assets/tr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokümantasyonu}}
diff --git a/assets/uk/@meta.texy b/assets/uk/@meta.texy
new file mode 100644
index 0000000000..96e2d9752a
--- /dev/null
+++ b/assets/uk/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документація Nette}}
diff --git a/best-practices/bg/@home.texy b/best-practices/bg/@home.texy
index 77b4bf9e08..808c4d31b7 100644
--- a/best-practices/bg/@home.texy
+++ b/best-practices/bg/@home.texy
@@ -67,6 +67,3 @@ Nette Приложения
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/bg/@meta.texy b/best-practices/bg/@meta.texy
new file mode 100644
index 0000000000..dc4e6c5b2b
--- /dev/null
+++ b/best-practices/bg/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Ръководства и процедури}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/bg/attribute-requires.texy b/best-practices/bg/attribute-requires.texy
index 8feeefe77a..c779502d44 100644
--- a/best-practices/bg/attribute-requires.texy
+++ b/best-practices/bg/attribute-requires.texy
@@ -175,5 +175,3 @@ class ApiPresenter extends Nette\Application\UI\Presenter
----------
Атрибутът `#[Requires]` ви дава голяма гъвкавост и контрол върху това как са достъпни вашите уеб страници. С помощта на прости, но мощни правила можете да повишите сигурността и правилното функциониране на вашето приложение. Както виждате, използването на атрибути в Nette може не само да улесни вашата работа, но и да я обезопаси.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/composer.texy b/best-practices/bg/composer.texy
index cd7c3805e0..2346c9485f 100644
--- a/best-practices/bg/composer.texy
+++ b/best-practices/bg/composer.texy
@@ -280,5 +280,3 @@ Composer е тясно свързан с инструмента за верси
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/creating-editing-form.texy b/best-practices/bg/creating-editing-form.texy
index 65f651bba7..5f4f84a06c 100644
--- a/best-practices/bg/creating-editing-form.texy
+++ b/best-practices/bg/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/dynamic-snippets.texy b/best-practices/bg/dynamic-snippets.texy
index e872d93897..c8baa990be 100644
--- a/best-practices/bg/dynamic-snippets.texy
+++ b/best-practices/bg/dynamic-snippets.texy
@@ -171,4 +171,3 @@ protected function createComponentLikeControl()
Почти сме готови: приложението вече ще работи с AJAX. И тук трябва да оптимизираме приложението, защото поради използването на Nette Database, при обработката на сигнала ненужно се зареждат всички статии от базата данни вместо само една. Предимството обаче е, че те няма да бъдат рендирани, тъй като ще се рендира само нашият компонент.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/editors-and-tools.texy b/best-practices/bg/editors-and-tools.texy
index a6a88722d8..89751ce259 100644
--- a/best-practices/bg/editors-and-tools.texy
+++ b/best-practices/bg/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Това беше инструмент, който тестваше средата за изпълнение на сървъра и информираше дали (и до каква степен) е възможно да се използва framework-ът. В момента Nette може да се използва на всеки сървър, който има минималната изисквана версия на PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/form-reuse.texy b/best-practices/bg/form-reuse.texy
index b8724ecb50..1af34cdd6f 100644
--- a/best-practices/bg/form-reuse.texy
+++ b/best-practices/bg/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/inject-method-attribute.texy b/best-practices/bg/inject-method-attribute.texy
index cfbb8cbf70..2d72ead00c 100644
--- a/best-practices/bg/inject-method-attribute.texy
+++ b/best-practices/bg/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Предимството на този начин на предаване на зависимости беше много икономичната форма на запис. Въпреки това, с появата на [constructor property promotion |https://blog.nette.org/bg/php-8-0-complete-overview-of-news#toc-constructor-property-promotion], изглежда по-лесно да се използва конструктор.
От друга страна, този начин страда от същите недостатъци като предаването на зависимости към свойства като цяло: нямаме контрол над промените в променливата и същевременно променливата става част от публичния интерфейс на класа, което е нежелателно.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/lets-create-contact-form.texy b/best-practices/bg/lets-create-contact-form.texy
index 9069f217f6..9070371fe2 100644
--- a/best-practices/bg/lets-create-contact-form.texy
+++ b/best-practices/bg/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
И е готово!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/microsites.texy b/best-practices/bg/microsites.texy
index 4b57abec8c..e29edcb2ed 100644
--- a/best-practices/bg/microsites.texy
+++ b/best-practices/bg/microsites.texy
@@ -61,5 +61,3 @@ PHP кодът в `index.php` първо [подготвя средата |boots
- Понякога може да ви е полезно [кеширането|caching:], например ако изтегляте и показвате фийдове.
В днешно време, когато скоростта и ефективността са ключови, е важно да имате инструменти, които ви позволяват да постигнете резултати без излишно забавяне. Nette framework ви предлага точно това - бърза разработка, сигурност и широк набор от инструменти, като Tracy и Latte, които опростяват процеса. Достатъчно е да инсталирате няколко Nette пакета и изграждането на такъв микросайт изведнъж става напълно лесно. И знаете, че никъде не се крие никаква дупка в сигурността.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/pagination.texy b/best-practices/bg/pagination.texy
index 16e609ce25..15a33b739e 100644
--- a/best-practices/bg/pagination.texy
+++ b/best-practices/bg/pagination.texy
@@ -271,4 +271,3 @@ class HomePresenter extends Nette\Application\UI\Presenter
По този начин внедрихме механизъм за пагиниране без използване на Paginator.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/passing-settings-to-presenters.texy b/best-practices/bg/passing-settings-to-presenters.texy
index de14fd76cf..076be18938 100644
--- a/best-practices/bg/passing-settings-to-presenters.texy
+++ b/best-practices/bg/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/post-links.texy b/best-practices/bg/post-links.texy
index 67f354a86c..452bb3b18a 100644
--- a/best-practices/bg/post-links.texy
+++ b/best-practices/bg/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Този подход не само подобрява сигурността на вашето приложение, но също така допринася за спазването на правилните уеб стандарти и практики. Чрез използването на методи POST за действия, променящи състоянието, ще постигнете по-стабилно и по-сигурно приложение.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/presenter-traits.texy b/best-practices/bg/presenter-traits.texy
index 4567d3f079..c2cf88f074 100644
--- a/best-practices/bg/presenter-traits.texy
+++ b/best-practices/bg/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/bg/restore-request.texy b/best-practices/bg/restore-request.texy
index f687d89ef5..191350748d 100644
--- a/best-practices/bg/restore-request.texy
+++ b/best-practices/bg/restore-request.texy
@@ -60,4 +60,3 @@ class SignPresenter extends Nette\Application\UI\Presenter
Ако обаче ключът е невалиден (например вече не съществува в сесията), методът не прави нищо. Следователно следва извикването на `$this->redirect('Admin:')`, което пренасочва към `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/cs/@home.texy b/best-practices/cs/@home.texy
index 84d96c8a34..612d75048f 100644
--- a/best-practices/cs/@home.texy
+++ b/best-practices/cs/@home.texy
@@ -67,6 +67,3 @@ Stovky záznamů z Posledních sobot a videí o Nette naleznete pod jednou stře
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/cs/@meta.texy b/best-practices/cs/@meta.texy
new file mode 100644
index 0000000000..0c9a1e9689
--- /dev/null
+++ b/best-practices/cs/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Návody a postupy}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/cs/attribute-requires.texy b/best-practices/cs/attribute-requires.texy
index 611855f14b..682d1640a5 100644
--- a/best-practices/cs/attribute-requires.texy
+++ b/best-practices/cs/attribute-requires.texy
@@ -175,5 +175,3 @@ Závěr
-----
Atribut `#[Requires]` vám dává velkou flexibilitu a kontrolu nad tím, jak jsou vaše webové stránky přístupné. Pomocí jednoduchých, ale mocných pravidel můžete zvýšit bezpečnost a správné fungování vaší aplikace. Jak vidíte, použití atributů v Nette může vaši práci nejen usnadnit, ale i zabezpečit.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/cs/composer.texy b/best-practices/cs/composer.texy
index 37d208b6f2..aebe726bbc 100644
--- a/best-practices/cs/composer.texy
+++ b/best-practices/cs/composer.texy
@@ -280,5 +280,3 @@ Composer je úzce propojený s verzovacím nástrojem [Git |https://git-scm.com]
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/cs/creating-editing-form.texy b/best-practices/cs/creating-editing-form.texy
index e8a713521a..d43c67faf8 100644
--- a/best-practices/cs/creating-editing-form.texy
+++ b/best-practices/cs/creating-editing-form.texy
@@ -29,11 +29,11 @@ class RecordPresenter extends Nette\Application\UI\Presenter
// ... přidáme políčka formuláře ...
- $form->onSuccess[] = [$this, 'recordFormSucceeded'];
+ $form->onSuccess[] = $this->recordFormSucceeded(...);
return $form;
}
- public function recordFormSucceeded(Form $form, array $data): void
+ private function recordFormSucceeded(Form $form, array $data): void
{
$this->facade->add($data); // přidání záznamu do databáze
$this->flashMessage('Successfully added');
@@ -91,11 +91,11 @@ class RecordPresenter extends Nette\Application\UI\Presenter
// ... přidáme políčka formuláře ...
$form->setDefaults($this->record); // nastavení výchozích hodnot
- $form->onSuccess[] = [$this, 'recordFormSucceeded'];
+ $form->onSuccess[] = $this->recordFormSucceeded(...);
return $form;
}
- public function recordFormSucceeded(Form $form, array $data): void
+ private function recordFormSucceeded(Form $form, array $data): void
{
$this->facade->update($this->record->id, $data); // aktualizace záznamu
$this->flashMessage('Successfully updated');
@@ -130,7 +130,6 @@ Záznam si uložíme do property `$record`, abychom jej měli k dispozici v meto
$this->facade->update($id, $data);
// ...
}
-}
```
Nicméně, a to by mělo být **nejdůležitejším poznatkem celého kódu**, musíme se při tvorbě formuláře ujistit, že akce je skutečně `edit`. Protože jinak by ověření v metodě `actionEdit()` vůbec neproběhlo!
@@ -153,7 +152,7 @@ class RecordPresenter extends Nette\Application\UI\Presenter
public function actionAdd(): void
{
$form = $this->getComponent('recordForm');
- $form->onSuccess[] = [$this, 'addingFormSucceeded'];
+ $form->onSuccess[] = $this->addingFormSucceeded(...);
}
public function actionEdit(int $id): void
@@ -168,7 +167,7 @@ class RecordPresenter extends Nette\Application\UI\Presenter
$form = $this->getComponent('recordForm');
$form->setDefaults($record); // nastavení výchozích hodnot
- $form->onSuccess[] = [$this, 'editingFormSucceeded'];
+ $form->onSuccess[] = $this->editingFormSucceeded(...);
}
protected function createComponentRecordForm(): Form
@@ -185,14 +184,14 @@ class RecordPresenter extends Nette\Application\UI\Presenter
return $form;
}
- public function addingFormSucceeded(Form $form, array $data): void
+ private function addingFormSucceeded(Form $form, array $data): void
{
$this->facade->add($data); // přidání záznamu do databáze
$this->flashMessage('Successfully added');
$this->redirect('...');
}
- public function editingFormSucceeded(Form $form, array $data): void
+ private function editingFormSucceeded(Form $form, array $data): void
{
$id = (int) $this->getParameter('id');
$this->facade->update($id, $data); // aktualizace záznamu
@@ -203,4 +202,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/cs/dynamic-snippets.texy b/best-practices/cs/dynamic-snippets.texy
index cc50c47acb..104844e59c 100644
--- a/best-practices/cs/dynamic-snippets.texy
+++ b/best-practices/cs/dynamic-snippets.texy
@@ -171,4 +171,3 @@ protected function createComponentLikeControl()
Máme téměř hotovo: aplikace nyní bude fungovat AJAXově. I zde nás čeká aplikaci optimalizovat, protože vzhledem k použití Nette Database se při zpracování signálu zbytečně načtou všechny články z databáze namísto jednoho. Výhodou však je, že nedojde k jejich vykreslování, protože se vyrenderuje skutečně jen naše komponenta.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/cs/editors-and-tools.texy b/best-practices/cs/editors-and-tools.texy
index a299c3f5eb..efbbd772ba 100644
--- a/best-practices/cs/editors-and-tools.texy
+++ b/best-practices/cs/editors-and-tools.texy
@@ -13,9 +13,9 @@ Rozhodně doporučujeme pro vývoj používat plnohodnotné IDE, jako je třeba
**NetBeans IDE** má podporu pro Nette, Latte a NEON už vestavěnou.
**PhpStorm**: nainstalujte si tyto pluginy v `Settings > Plugins > Marketplace`
-- Nette framework helpers
-- Latte
-- NEON support
+- [Nette |https://plugins.jetbrains.com/plugin/28342-nette]
+- [Latte |https://plugins.jetbrains.com/plugin/24218-latte-support] nebo [Latte Pro |https://plugins.jetbrains.com/plugin/19661-latte-pro]
+- [NEON |https://plugins.jetbrains.com/plugin/28338-neon] nebo [NEON / Nette support |https://plugins.jetbrains.com/plugin/18387-neon-nette-support]
- Nette Tester
**VS Code**: najděte v marketplace "Nette Latte + Neon" plugin.
@@ -82,5 +82,3 @@ Requirements Checker
====================
Šlo o nástroj, který testoval běhové prostředí serveru a informoval, zda (a do jaké míry) je možné framework používat. V současnosti je Nette možné používat na každém serveru, který má minimální požadovanou verzi PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/cs/form-reuse.texy b/best-practices/cs/form-reuse.texy
index b1310fba6b..ac95ca2617 100644
--- a/best-practices/cs/form-reuse.texy
+++ b/best-practices/cs/form-reuse.texy
@@ -193,11 +193,11 @@ class EditFormFactory
$form->addText('title', 'Titulek:');
// zde se přidávají další formulářová pole
$form->addSubmit('send', 'Odeslat');
- $form->onSuccess[] = [$this, 'processForm'];
+ $form->onSuccess[] = $this->processForm(...);
return $form;
}
- public function processForm(Form $form, array $data): void
+ private function processForm(Form $form, array $data): void
{
try {
// zpracování odeslaných dat
@@ -284,12 +284,12 @@ class EditControl extends Nette\Application\UI\Control
$form->addText('title', 'Titulek:');
// zde se přidávají další formulářová pole
$form->addSubmit('send', 'Odeslat');
- $form->onSuccess[] = [$this, 'processForm'];
+ $form->onSuccess[] = $this->processForm(...);
return $form;
}
- public function processForm(Form $form, array $data): void
+ private function processForm(Form $form, array $data): void
{
try {
// zpracování odeslaných dat
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/cs/inject-method-attribute.texy b/best-practices/cs/inject-method-attribute.texy
index e12dcbfffd..f831f0535f 100644
--- a/best-practices/cs/inject-method-attribute.texy
+++ b/best-practices/cs/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Výhodou tohoto způsobu předávání závislostí byla velice úsporná podoba zápisu. Nicméně s příchodem [constructor property promotion |https://blog.nette.org/cs/php-8-0-kompletni-prehled-novinek#toc-constructor-property-promotion] se jeví snazší použít konstruktor.
Naopak tento způsob trpí stejnými nedostatky, jako předávání závislosti do properties obecně: nemáme kontrolu nad změnami v proměnné a zároveň se proměnná stává součástí veřejného rozhraní třídy, což je nežádnoucí.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/cs/lets-create-contact-form.texy b/best-practices/cs/lets-create-contact-form.texy
index a56d0d61f2..23fde0f0c5 100644
--- a/best-practices/cs/lets-create-contact-form.texy
+++ b/best-practices/cs/lets-create-contact-form.texy
@@ -24,11 +24,11 @@ class HomePresenter extends Presenter
$form->addTextarea('message', 'Zpráva:')
->setRequired('Zadejte zprávu');
$form->addSubmit('send', 'Odeslat');
- $form->onSuccess[] = [$this, 'contactFormSucceeded'];
+ $form->onSuccess[] = $this->contactFormSucceeded(...);
return $form;
}
- public function contactFormSucceeded(Form $form, $data): void
+ private function contactFormSucceeded(Form $form, $data): void
{
// odeslání emailu
}
@@ -48,9 +48,6 @@ Komponentu `contactForm` necháme vykreslit v šabloně `Home/default.latte`:
Pro samotné odeslání emailu vytvoříme novou třídu, kterou nazveme `ContactFacade` a umístíme ji do souboru `app/Model/ContactFacade.php`:
```php
-onSuccess[] = [$this, 'signInFormSubmitted'];
+ $form->onSuccess[] = $this->signInFormSubmitted(...);
return $form;
}
- public function signInFormSubmitted($form)
+ private function signInFormSubmitted($form)
{
// ... tady uživatele přihlásíme ...
@@ -60,4 +60,3 @@ Metodě `restoreRequest()` předáme klíč uloženého požadavku a ona přesm
Pokud je ale klíč neplatný (například už v session neexistuje), metoda neudělá nic. Následuje tedy volání `$this->redirect('Admin:')`, které přesměruje na `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/de/@home.texy b/best-practices/de/@home.texy
index 5e611bb9b7..d855293435 100644
--- a/best-practices/de/@home.texy
+++ b/best-practices/de/@home.texy
@@ -67,6 +67,3 @@ Hunderte von Aufzeichnungen von "Poslední sobota" und Videos über Nette finden
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/de/@meta.texy b/best-practices/de/@meta.texy
new file mode 100644
index 0000000000..c3bc189de7
--- /dev/null
+++ b/best-practices/de/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Anleitungen und Verfahren}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/de/attribute-requires.texy b/best-practices/de/attribute-requires.texy
index 054c34d812..b6a5b9f6c2 100644
--- a/best-practices/de/attribute-requires.texy
+++ b/best-practices/de/attribute-requires.texy
@@ -175,5 +175,3 @@ Fazit
-----
Das Attribut `#[Requires]` gibt Ihnen große Flexibilität und Kontrolle darüber, wie auf Ihre Webseiten zugegriffen wird. Mit einfachen, aber leistungsstarken Regeln können Sie die Sicherheit und die korrekte Funktion Ihrer Anwendung erhöhen. Wie Sie sehen, kann die Verwendung von Attributen in Nette Ihre Arbeit nicht nur erleichtern, sondern auch sicherer machen.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/composer.texy b/best-practices/de/composer.texy
index 35ae323e70..554def763b 100644
--- a/best-practices/de/composer.texy
+++ b/best-practices/de/composer.texy
@@ -280,5 +280,3 @@ Composer ist eng mit dem Versionierungswerkzeug [Git |https://git-scm.com] verbu
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/creating-editing-form.texy b/best-practices/de/creating-editing-form.texy
index ee98f56405..4238bf13fa 100644
--- a/best-practices/de/creating-editing-form.texy
+++ b/best-practices/de/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/de/dynamic-snippets.texy b/best-practices/de/dynamic-snippets.texy
index 085d4e735f..b4ea7a67d5 100644
--- a/best-practices/de/dynamic-snippets.texy
+++ b/best-practices/de/dynamic-snippets.texy
@@ -171,4 +171,3 @@ Das View-Template wird auf das notwendige Minimum reduziert (und völlig frei vo
Wir sind fast fertig: Die Anwendung wird nun AJAX-fähig funktionieren. Auch hier müssen wir die Anwendung optimieren, da aufgrund der Verwendung von Nette Database bei der Signalverarbeitung unnötigerweise alle Artikel aus der Datenbank anstelle von nur einem geladen werden. Der Vorteil ist jedoch, dass es nicht zu deren Rendern kommt, da tatsächlich nur unsere Komponente gerendert wird.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/de/editors-and-tools.texy b/best-practices/de/editors-and-tools.texy
index ea98e74731..bda0c9c7fb 100644
--- a/best-practices/de/editors-and-tools.texy
+++ b/best-practices/de/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Dies war ein Werkzeug, das die Laufzeitumgebung des Servers testete und informierte, ob (und inwieweit) das Framework verwendet werden kann. Derzeit kann Nette auf jedem Server verwendet werden, der die minimal erforderliche PHP-Version hat.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/form-reuse.texy b/best-practices/de/form-reuse.texy
index 417a3bf484..0da82ed0e4 100644
--- a/best-practices/de/form-reuse.texy
+++ b/best-practices/de/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/inject-method-attribute.texy b/best-practices/de/inject-method-attribute.texy
index 151a0304fb..45788eca01 100644
--- a/best-practices/de/inject-method-attribute.texy
+++ b/best-practices/de/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Der Vorteil dieser Art der Abhängigkeitsübergabe war die sehr sparsame Schreibweise. Mit der Einführung von [Constructor Property Promotion |https://blog.nette.org/de/php-8-0-kompletter-ueberblick-ueber-neuerungen#toc-constructor-property-promotion] erscheint es jedoch einfacher, den Konstruktor zu verwenden.
Im Gegenteil leidet diese Methode unter denselben Nachteilen wie die Übergabe von Abhängigkeiten an Eigenschaften im Allgemeinen: Wir haben keine Kontrolle über Änderungen in der Variablen, und gleichzeitig wird die Variable Teil der öffentlichen Schnittstelle der Klasse, was unerwünscht ist.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/lets-create-contact-form.texy b/best-practices/de/lets-create-contact-form.texy
index dcdb943252..998313e20f 100644
--- a/best-practices/de/lets-create-contact-form.texy
+++ b/best-practices/de/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
Und fertig!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/microsites.texy b/best-practices/de/microsites.texy
index 289a0cc918..71eac0ad76 100644
--- a/best-practices/de/microsites.texy
+++ b/best-practices/de/microsites.texy
@@ -61,5 +61,3 @@ Warum Nette für Microsites verwenden?
- Manchmal kann Ihnen [Caching|caching:] nützlich sein, zum Beispiel wenn Sie Feeds herunterladen und anzeigen.
In der heutigen Zeit, in der Geschwindigkeit und Effizienz entscheidend sind, ist es wichtig, Werkzeuge zu haben, die es Ihnen ermöglichen, Ergebnisse ohne unnötige Verzögerung zu erzielen. Das Nette Framework bietet Ihnen genau das - schnelle Entwicklung, Sicherheit und eine breite Palette von Werkzeugen wie Tracy und Latte, die den Prozess vereinfachen. Installieren Sie einfach ein paar Nette-Pakete und der Aufbau einer solchen Microsite ist plötzlich ein Kinderspiel. Und Sie wissen, dass sich nirgendwo eine Sicherheitslücke verbirgt.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/pagination.texy b/best-practices/de/pagination.texy
index 8484097040..17aabcacc3 100644
--- a/best-practices/de/pagination.texy
+++ b/best-practices/de/pagination.texy
@@ -271,4 +271,3 @@ Da wir nun keinen Paginator an das Template senden, passen wir den Teil an, der
Auf diese Weise haben wir den Paginierungsmechanismus ohne Verwendung des Paginators implementiert.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/de/passing-settings-to-presenters.texy b/best-practices/de/passing-settings-to-presenters.texy
index 216b4823b6..d84c9fb780 100644
--- a/best-practices/de/passing-settings-to-presenters.texy
+++ b/best-practices/de/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/post-links.texy b/best-practices/de/post-links.texy
index f340fa81ab..f4f90e1f24 100644
--- a/best-practices/de/post-links.texy
+++ b/best-practices/de/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Dieser Ansatz verbessert nicht nur die Sicherheit Ihrer Anwendung, sondern trägt auch zur Einhaltung korrekter Webstandards und Praktiken bei. Durch die Verwendung von POST-Methoden für zustandsändernde Aktionen erreichen Sie eine robustere und sicherere Anwendung.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/presenter-traits.texy b/best-practices/de/presenter-traits.texy
index 3ef62a5726..e6cf4290dc 100644
--- a/best-practices/de/presenter-traits.texy
+++ b/best-practices/de/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/de/restore-request.texy b/best-practices/de/restore-request.texy
index 50c90b7a6b..957f7c6605 100644
--- a/best-practices/de/restore-request.texy
+++ b/best-practices/de/restore-request.texy
@@ -60,4 +60,3 @@ Wir übergeben der Methode `restoreRequest()` den Schlüssel der gespeicherten A
Wenn der Schlüssel jedoch ungültig ist (z. B. nicht mehr in der Session existiert oder der Benutzer nicht übereinstimmt), tut die Methode nichts. Es folgt also der Aufruf `$this->redirect('Admin:')`, der zum `AdminPresenter` (oder einer anderen Standardseite nach dem Login) weiterleitet.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/el/@home.texy b/best-practices/el/@home.texy
index ad79a76071..0e8088a224 100644
--- a/best-practices/el/@home.texy
+++ b/best-practices/el/@home.texy
@@ -67,6 +67,3 @@
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/el/@meta.texy b/best-practices/el/@meta.texy
new file mode 100644
index 0000000000..9ae15ea14a
--- /dev/null
+++ b/best-practices/el/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Οδηγοί και διαδικασίες}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/el/attribute-requires.texy b/best-practices/el/attribute-requires.texy
index a91a38d7a9..6a3211185c 100644
--- a/best-practices/el/attribute-requires.texy
+++ b/best-practices/el/attribute-requires.texy
@@ -175,5 +175,3 @@ class ApiPresenter extends Nette\Application\UI\Presenter
----------
Το attribute `#[Requires]` σας δίνει μεγάλη ευελιξία και έλεγχο στο πώς είναι προσβάσιμες οι ιστοσελίδες σας. Χρησιμοποιώντας απλούς αλλά ισχυρούς κανόνες, μπορείτε να αυξήσετε την ασφάλεια και τη σωστή λειτουργία της εφαρμογής σας. Όπως βλέπετε, η χρήση attributes στο Nette μπορεί όχι μόνο να διευκολύνει τη δουλειά σας, αλλά και να την ασφαλίσει.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/composer.texy b/best-practices/el/composer.texy
index 1a50f9f416..9e0a6a7715 100644
--- a/best-practices/el/composer.texy
+++ b/best-practices/el/composer.texy
@@ -280,5 +280,3 @@ composer thanks
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/creating-editing-form.texy b/best-practices/el/creating-editing-form.texy
index 039b46fa99..4566a81628 100644
--- a/best-practices/el/creating-editing-form.texy
+++ b/best-practices/el/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/el/dynamic-snippets.texy b/best-practices/el/dynamic-snippets.texy
index 618a00787c..134ee63491 100644
--- a/best-practices/el/dynamic-snippets.texy
+++ b/best-practices/el/dynamic-snippets.texy
@@ -171,4 +171,3 @@ protected function createComponentLikeControl()
Έχουμε σχεδόν τελειώσει: η εφαρμογή τώρα θα λειτουργεί με AJAX. Και εδώ μας περιμένει η βελτιστοποίηση της εφαρμογής, επειδή λόγω της χρήσης του Nette Database, κατά την επεξεργασία του σήματος φορτώνονται άσκοπα όλα τα άρθρα από τη βάση δεδομένων αντί για ένα. Το πλεονέκτημα όμως είναι ότι δεν θα γίνει η σχεδίασή τους, επειδή θα αποδοθεί πραγματικά μόνο το component μας.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/el/editors-and-tools.texy b/best-practices/el/editors-and-tools.texy
index 85eb06f8b5..a5d46f739c 100644
--- a/best-practices/el/editors-and-tools.texy
+++ b/best-practices/el/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Ήταν ένα εργαλείο που δοκίμαζε το περιβάλλον εκτέλεσης του server και ενημέρωνε αν (και σε ποιο βαθμό) ήταν δυνατό να χρησιμοποιηθεί το framework. Επί του παρόντος, το Nette μπορεί να χρησιμοποιηθεί σε κάθε server που έχει την ελάχιστη απαιτούμενη έκδοση PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/form-reuse.texy b/best-practices/el/form-reuse.texy
index 76e7dfe7a4..28f0bf1b38 100644
--- a/best-practices/el/form-reuse.texy
+++ b/best-practices/el/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/inject-method-attribute.texy b/best-practices/el/inject-method-attribute.texy
index d8a6f6a25b..a13bfcff48 100644
--- a/best-practices/el/inject-method-attribute.texy
+++ b/best-practices/el/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Το πλεονέκτημα αυτού του τρόπου περάσματος εξαρτήσεων ήταν η πολύ οικονομική μορφή γραφής. Ωστόσο, με την έλευση του [constructor property promotion |https://blog.nette.org/el/php-8-0-complete-overview-of-news#toc-constructor-property-promotion], φαίνεται ευκολότερο να χρησιμοποιηθεί ο constructor.
Αντίθετα, αυτός ο τρόπος πάσχει από τις ίδιες αδυναμίες με το πέρασμα εξαρτήσεων σε properties γενικά: δεν έχουμε έλεγχο στις αλλαγές στη μεταβλητή και ταυτόχρονα η μεταβλητή γίνεται μέρος του δημόσιου interface της κλάσης, πράγμα που είναι ανεπιθύμητο.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/lets-create-contact-form.texy b/best-practices/el/lets-create-contact-form.texy
index c713cadb6d..fa4e52cc69 100644
--- a/best-practices/el/lets-create-contact-form.texy
+++ b/best-practices/el/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
Και τελειώσαμε!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/microsites.texy b/best-practices/el/microsites.texy
index 0b78aab73a..2224119362 100644
--- a/best-practices/el/microsites.texy
+++ b/best-practices/el/microsites.texy
@@ -61,5 +61,3 @@ $container->getByType(Nette\Application\Application::class)->run();
- Μερικές φορές μπορεί να σας φανεί χρήσιμο το [caching |caching:], για παράδειγμα αν κατεβάζετε και εμφανίζετε feeds.
Στη σημερινή εποχή, όπου η ταχύτητα και η αποτελεσματικότητα είναι καθοριστικής σημασίας, είναι σημαντικό να έχετε εργαλεία που σας επιτρέπουν να επιτύχετε αποτελέσματα χωρίς περιττές καθυστερήσεις. Το Nette framework σας προσφέρει ακριβώς αυτό - γρήγορη ανάπτυξη, ασφάλεια και ένα ευρύ φάσμα εργαλείων, όπως το Tracy και το Latte, που απλοποιούν τη διαδικασία. Αρκεί να εγκαταστήσετε μερικά πακέτα Nette και η κατασκευή ενός τέτοιου microsite γίνεται ξαφνικά παιχνιδάκι. Και ξέρετε ότι πουθενά δεν κρύβεται καμία τρύπα ασφαλείας.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/pagination.texy b/best-practices/el/pagination.texy
index 1a8b3e2071..cdefb763e4 100644
--- a/best-practices/el/pagination.texy
+++ b/best-practices/el/pagination.texy
@@ -271,4 +271,3 @@ class HomePresenter extends Nette\Application\UI\Presenter
Με αυτόν τον τρόπο υλοποιήσαμε τον μηχανισμό σελίδωσης χωρίς τη χρήση του Paginator.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/el/passing-settings-to-presenters.texy b/best-practices/el/passing-settings-to-presenters.texy
index 5b5356358b..f600bbb498 100644
--- a/best-practices/el/passing-settings-to-presenters.texy
+++ b/best-practices/el/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/post-links.texy b/best-practices/el/post-links.texy
index 2454034772..a6147e263a 100644
--- a/best-practices/el/post-links.texy
+++ b/best-practices/el/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Αυτή η προσέγγιση όχι μόνο βελτιώνει την ασφάλεια της εφαρμογής σας, αλλά συμβάλλει επίσης στην τήρηση των σωστών web προτύπων και πρακτικών. Χρησιμοποιώντας τις μεθόδους POST για ενέργειες που αλλάζουν την κατάσταση, επιτυγχάνετε μια πιο στιβαρή και ασφαλή εφαρμογή.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/presenter-traits.texy b/best-practices/el/presenter-traits.texy
index 352d127baa..b5c9e24f28 100644
--- a/best-practices/el/presenter-traits.texy
+++ b/best-practices/el/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/el/restore-request.texy b/best-practices/el/restore-request.texy
index 28802cb67d..631a0c432b 100644
--- a/best-practices/el/restore-request.texy
+++ b/best-practices/el/restore-request.texy
@@ -60,4 +60,3 @@ class SignPresenter extends Nette\Application\UI\Presenter
Αν όμως το κλειδί είναι άκυρο (για παράδειγμα δεν υπάρχει πλέον στο session), η μέθοδος δεν κάνει τίποτα. Ακολουθεί επομένως η κλήση `$this->redirect('Admin:')`, η οποία ανακατευθύνει στον `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/en/@home.texy b/best-practices/en/@home.texy
index 651c9a82a7..04508b55aa 100644
--- a/best-practices/en/@home.texy
+++ b/best-practices/en/@home.texy
@@ -67,6 +67,3 @@ Hundreds of recordings from Last Saturday meetups and videos about Nette can be
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/en/@meta.texy b/best-practices/en/@meta.texy
new file mode 100644
index 0000000000..10c126830b
--- /dev/null
+++ b/best-practices/en/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Tutorials and Best Practices}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/en/attribute-requires.texy b/best-practices/en/attribute-requires.texy
index 75e296e8b0..54da7db490 100644
--- a/best-practices/en/attribute-requires.texy
+++ b/best-practices/en/attribute-requires.texy
@@ -175,5 +175,3 @@ Conclusion
----------
The `#[Requires]` attribute gives you great flexibility and control over how your web pages are accessed. Using simple, yet powerful rules, you can enhance the security and proper functioning of your application. As you can see, using attributes in Nette can not only simplify your work but also secure it.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/en/composer.texy b/best-practices/en/composer.texy
index dd972f2121..1e08a82668 100644
--- a/best-practices/en/composer.texy
+++ b/best-practices/en/composer.texy
@@ -280,5 +280,3 @@ Composer is closely integrated with the version control tool [Git |https://git-s
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/en/creating-editing-form.texy b/best-practices/en/creating-editing-form.texy
index 6a76e2aeb0..86003dffc6 100644
--- a/best-practices/en/creating-editing-form.texy
+++ b/best-practices/en/creating-editing-form.texy
@@ -29,11 +29,11 @@ class RecordPresenter extends Nette\Application\UI\Presenter
// ... add form fields ...
- $form->onSuccess[] = [$this, 'recordFormSucceeded'];
+ $form->onSuccess[] = $this->recordFormSucceeded(...);
return $form;
}
- public function recordFormSucceeded(Form $form, array $data): void
+ private function recordFormSucceeded(Form $form, array $data): void
{
$this->facade->add($data); // add record to the database
$this->flashMessage('Successfully added');
@@ -91,11 +91,11 @@ class RecordPresenter extends Nette\Application\UI\Presenter
// ... add form fields ...
$form->setDefaults($this->record); // set default values
- $form->onSuccess[] = [$this, 'recordFormSucceeded'];
+ $form->onSuccess[] = $this->recordFormSucceeded(...);
return $form;
}
- public function recordFormSucceeded(Form $form, array $data): void
+ private function recordFormSucceeded(Form $form, array $data): void
{
$this->facade->update($this->record->id, $data); // update record
$this->flashMessage('Successfully updated');
@@ -130,7 +130,6 @@ We store the record in the `$record` property, making it available in the `creat
$this->facade->update($id, $data);
// ...
}
-}
```
However, and this should be **the most important takeaway from the entire code**, we must ensure the action is indeed `edit` when creating the form. Otherwise, the verification in the `actionEdit()` method would not occur at all!
@@ -153,7 +152,7 @@ class RecordPresenter extends Nette\Application\UI\Presenter
public function actionAdd(): void
{
$form = $this->getComponent('recordForm');
- $form->onSuccess[] = [$this, 'addingFormSucceeded'];
+ $form->onSuccess[] = $this->addingFormSucceeded(...);
}
public function actionEdit(int $id): void
@@ -168,7 +167,7 @@ class RecordPresenter extends Nette\Application\UI\Presenter
$form = $this->getComponent('recordForm');
$form->setDefaults($record); // set default values
- $form->onSuccess[] = [$this, 'editingFormSucceeded'];
+ $form->onSuccess[] = $this->editingFormSucceeded(...);
}
protected function createComponentRecordForm(): Form
@@ -185,14 +184,14 @@ class RecordPresenter extends Nette\Application\UI\Presenter
return $form;
}
- public function addingFormSucceeded(Form $form, array $data): void
+ private function addingFormSucceeded(Form $form, array $data): void
{
$this->facade->add($data); // add record to the database
$this->flashMessage('Successfully added');
$this->redirect('...');
}
- public function editingFormSucceeded(Form $form, array $data): void
+ private function editingFormSucceeded(Form $form, array $data): void
{
$id = (int) $this->getParameter('id');
$this->facade->update($id, $data); // update record
@@ -203,4 +202,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/en/dynamic-snippets.texy b/best-practices/en/dynamic-snippets.texy
index a9221516a9..144d00268a 100644
--- a/best-practices/en/dynamic-snippets.texy
+++ b/best-practices/en/dynamic-snippets.texy
@@ -171,4 +171,3 @@ The view's template shrinks to the bare minimum (and is completely free of snipp
We're almost finished: the application will now function with AJAX. Here too, optimization is needed because, due to the use of Nette Database, signal processing unnecessarily loads all articles from the database instead of just the relevant one. The advantage, however, is that no unnecessary rendering occurs, as only the specific component instance is rendered.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/en/editors-and-tools.texy b/best-practices/en/editors-and-tools.texy
index 48fe84f530..e81b575eb6 100644
--- a/best-practices/en/editors-and-tools.texy
+++ b/best-practices/en/editors-and-tools.texy
@@ -13,9 +13,9 @@ We strongly recommend using a full-featured IDE for development, like PhpStorm,
**NetBeans IDE** has built-in support for Nette, Latte, and NEON.
**PhpStorm**: Install these plugins via `Settings > Plugins > Marketplace`:
-- Nette framework helpers
-- Latte
-- NEON support
+- [Nette |https://plugins.jetbrains.com/plugin/28342-nette]
+- [Latte |https://plugins.jetbrains.com/plugin/24218-latte-support] or [Latte Pro |https://plugins.jetbrains.com/plugin/19661-latte-pro]
+- [NEON |https://plugins.jetbrains.com/plugin/28338-neon] or [NEON / Nette support |https://plugins.jetbrains.com/plugin/18387-neon-nette-support]
- Nette Tester
**VS Code**: Find the "Nette Latte + Neon" plugin in the marketplace.
@@ -82,5 +82,3 @@ Requirements Checker
====================
This was a tool that tested the server's runtime environment and indicated whether (and to what extent) the framework could be used. Currently, Nette can be used on any server that meets the minimum required PHP version.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/en/form-reuse.texy b/best-practices/en/form-reuse.texy
index 2924b3dd09..2d91c006fc 100644
--- a/best-practices/en/form-reuse.texy
+++ b/best-practices/en/form-reuse.texy
@@ -193,11 +193,11 @@ class EditFormFactory
$form->addText('title', 'Title:');
// additional form fields are added here
$form->addSubmit('send', 'Save');
- $form->onSuccess[] = [$this, 'processForm'];
+ $form->onSuccess[] = $this->processForm(...);
return $form;
}
- public function processForm(Form $form, array $data): void
+ private function processForm(Form $form, array $data): void
{
try {
// processing of submitted data
@@ -284,12 +284,12 @@ class EditControl extends Nette\Application\UI\Control
$form->addText('title', 'Title:');
// additional form fields are added here
$form->addSubmit('send', 'Save');
- $form->onSuccess[] = [$this, 'processForm'];
+ $form->onSuccess[] = $this->processForm(...);
return $form;
}
- public function processForm(Form $form, array $data): void
+ private function processForm(Form $form, array $data): void
{
try {
// processing of submitted data
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/en/inject-method-attribute.texy b/best-practices/en/inject-method-attribute.texy
index a3db1098dc..b1c36d8df1 100644
--- a/best-practices/en/inject-method-attribute.texy
+++ b/best-practices/en/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
The advantage of this dependency passing method was its very concise syntax. However, with the introduction of [constructor property promotion |https://blog.nette.org/en/php-8-0-complete-overview-of-news#toc-constructor-property-promotion], using the constructor often appears simpler.
Conversely, this method suffers from the same drawbacks as property injection in general: we lack control over changes to the variable, and the variable becomes part of the class's public interface, which is generally undesirable.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/en/lets-create-contact-form.texy b/best-practices/en/lets-create-contact-form.texy
index 3f1c5f95fe..695985f569 100644
--- a/best-practices/en/lets-create-contact-form.texy
+++ b/best-practices/en/lets-create-contact-form.texy
@@ -24,11 +24,11 @@ class HomePresenter extends Presenter
$form->addTextarea('message', 'Message:')
->setRequired('Please enter a message');
$form->addSubmit('send', 'Send');
- $form->onSuccess[] = [$this, 'contactFormSucceeded'];
+ $form->onSuccess[] = $this->contactFormSucceeded(...);
return $form;
}
- public function contactFormSucceeded(Form $form, $data): void
+ private function contactFormSucceeded(Form $form, $data): void
{
// sending an email
}
@@ -48,9 +48,6 @@ Let's render the `contactForm` component in the `Home/default.latte` template:
For sending the email itself, we'll create a new class named `ContactFacade` and place it in the file `app/Model/ContactFacade.php`:
```php
-onSuccess[] = [$this, 'signInFormSubmitted'];
+ $form->onSuccess[] = $this->signInFormSubmitted(...);
return $form;
}
- public function signInFormSubmitted($form)
+ private function signInFormSubmitted($form)
{
// ... log the user in here ...
@@ -60,4 +60,3 @@ We pass the key (`$this->backlink`) of the stored request to the `restoreRequest
However, if the key is invalid (e.g., it has expired from the session), the method does nothing. Therefore, the subsequent call `$this->redirect('Admin:')` acts as a fallback, redirecting to a default page like `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/es/@home.texy b/best-practices/es/@home.texy
index 7291597010..6a6ee9df47 100644
--- a/best-practices/es/@home.texy
+++ b/best-practices/es/@home.texy
@@ -67,6 +67,3 @@ Cientos de grabaciones de los Últimos Sábados y vídeos sobre Nette se pueden
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/es/@meta.texy b/best-practices/es/@meta.texy
new file mode 100644
index 0000000000..524cb19ad0
--- /dev/null
+++ b/best-practices/es/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Tutoriales y procedimientos}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/es/attribute-requires.texy b/best-practices/es/attribute-requires.texy
index bf04cca318..0eebe50721 100644
--- a/best-practices/es/attribute-requires.texy
+++ b/best-practices/es/attribute-requires.texy
@@ -175,5 +175,3 @@ Conclusión
----------
El atributo `#[Requires]` le da una gran flexibilidad y control sobre cómo son accesibles sus páginas web. Usando reglas simples pero potentes, puede aumentar la seguridad y el correcto funcionamiento de su aplicación. Como puede ver, el uso de atributos en Nette no solo puede facilitar su trabajo, sino también asegurarlo.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/composer.texy b/best-practices/es/composer.texy
index eabb093dd9..20959bbc87 100644
--- a/best-practices/es/composer.texy
+++ b/best-practices/es/composer.texy
@@ -280,5 +280,3 @@ Composer está estrechamente vinculado con la herramienta de versionado [Git |ht
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/creating-editing-form.texy b/best-practices/es/creating-editing-form.texy
index 58a6acaec9..9d44a9d52f 100644
--- a/best-practices/es/creating-editing-form.texy
+++ b/best-practices/es/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/es/dynamic-snippets.texy b/best-practices/es/dynamic-snippets.texy
index 2b69e3afe9..37ca43eec5 100644
--- a/best-practices/es/dynamic-snippets.texy
+++ b/best-practices/es/dynamic-snippets.texy
@@ -171,4 +171,3 @@ La plantilla de la vista se reduce al mínimo indispensable (¡y completamente l
Casi hemos terminado: la aplicación ahora funcionará con AJAX. Aquí también tendremos que optimizar la aplicación, porque debido al uso de Nette Database, al procesar la señal se cargan innecesariamente todos los artículos de la base de datos en lugar de uno solo. Sin embargo, la ventaja es que no se renderizarán, ya que realmente solo se renderizará nuestro componente.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/es/editors-and-tools.texy b/best-practices/es/editors-and-tools.texy
index 3c8cd48632..36d9c62866 100644
--- a/best-practices/es/editors-and-tools.texy
+++ b/best-practices/es/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Era una herramienta que probaba el entorno de ejecución del servidor e informaba si (y en qué medida) se podía utilizar el framework. Actualmente, Nette se puede utilizar en cualquier servidor que tenga la versión mínima requerida de PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/form-reuse.texy b/best-practices/es/form-reuse.texy
index dfc21839d3..3998002707 100644
--- a/best-practices/es/form-reuse.texy
+++ b/best-practices/es/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/inject-method-attribute.texy b/best-practices/es/inject-method-attribute.texy
index e21b9f45c4..c24c918236 100644
--- a/best-practices/es/inject-method-attribute.texy
+++ b/best-practices/es/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
La ventaja de esta forma de pasar dependencias era una sintaxis muy concisa. Sin embargo, con la llegada de [constructor property promotion |https://blog.nette.org/es/php-8-0-complete-overview-of-news#toc-constructor-property-promotion], parece más fácil usar el constructor.
Por el contrario, esta forma sufre las mismas deficiencias que pasar dependencias a propiedades en general: no tenemos control sobre los cambios en la variable y, al mismo tiempo, la variable se convierte en parte de la interfaz pública de la clase, lo cual no es deseable.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/lets-create-contact-form.texy b/best-practices/es/lets-create-contact-form.texy
index 75d68824d4..208b6174f5 100644
--- a/best-practices/es/lets-create-contact-form.texy
+++ b/best-practices/es/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
¡Y listo!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/microsites.texy b/best-practices/es/microsites.texy
index 175ef361bf..392f299d5f 100644
--- a/best-practices/es/microsites.texy
+++ b/best-practices/es/microsites.texy
@@ -61,5 +61,3 @@ El código PHP en `index.php` primero [prepara el entorno |bootstrap:], luego de
- A veces te puede resultar útil el [caching|caching:], por ejemplo, si descargas y muestras feeds.
En la actualidad, donde la velocidad y la eficiencia son clave, es importante tener herramientas que te permitan lograr resultados sin demoras innecesarias. Nette framework te ofrece precisamente eso: desarrollo rápido, seguridad y una amplia gama de herramientas, como Tracy y Latte, que simplifican el proceso. Simplemente instala algunos paquetes de Nette y construir un micrositio así se convierte de repente en un juego de niños. Y sabes que no hay ninguna brecha de seguridad oculta en ninguna parte.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/pagination.texy b/best-practices/es/pagination.texy
index 8874e3b595..13d443cbaf 100644
--- a/best-practices/es/pagination.texy
+++ b/best-practices/es/pagination.texy
@@ -271,4 +271,3 @@ Dado que ahora no enviamos Paginator a la plantilla, modificaremos la parte que
De esta manera, hemos implementado el mecanismo de paginación sin usar Paginator.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/es/passing-settings-to-presenters.texy b/best-practices/es/passing-settings-to-presenters.texy
index ae9e7018bd..a54e1ab5da 100644
--- a/best-practices/es/passing-settings-to-presenters.texy
+++ b/best-practices/es/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/post-links.texy b/best-practices/es/post-links.texy
index 74f40fbae6..8b0d2e0bab 100644
--- a/best-practices/es/post-links.texy
+++ b/best-practices/es/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Este enfoque no solo mejora la seguridad de tu aplicación, sino que también contribuye al cumplimiento de los estándares y prácticas web correctos. Al utilizar métodos POST para acciones que cambian el estado, lograrás una aplicación más robusta y segura.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/presenter-traits.texy b/best-practices/es/presenter-traits.texy
index c61482980a..b1dc7af72f 100644
--- a/best-practices/es/presenter-traits.texy
+++ b/best-practices/es/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/es/restore-request.texy b/best-practices/es/restore-request.texy
index 64439d3481..23de10d19f 100644
--- a/best-practices/es/restore-request.texy
+++ b/best-practices/es/restore-request.texy
@@ -60,4 +60,3 @@ Pasamos la clave de la solicitud guardada al método `restoreRequest()` y este r
Sin embargo, si la clave no es válida (por ejemplo, ya no existe en la sesión), el método no hace nada. Por lo tanto, sigue la llamada `$this->redirect('Admin:')`, que redirige a `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/@home.texy b/best-practices/fr/@home.texy
index d9f738390c..829741034c 100644
--- a/best-practices/fr/@home.texy
+++ b/best-practices/fr/@home.texy
@@ -67,6 +67,3 @@ Des centaines d'enregistrements des Derniers Samedis et de vidéos sur Nette peu
-
-{{sitename: Bonnes pratiques}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/fr/@meta.texy b/best-practices/fr/@meta.texy
new file mode 100644
index 0000000000..ae1deef2d5
--- /dev/null
+++ b/best-practices/fr/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Tutoriels et bonnes pratiques}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/fr/attribute-requires.texy b/best-practices/fr/attribute-requires.texy
index b93b664e1f..afeb4699c6 100644
--- a/best-practices/fr/attribute-requires.texy
+++ b/best-practices/fr/attribute-requires.texy
@@ -175,5 +175,3 @@ Conclusion
----------
L'attribut `#[Requires]` vous offre une grande flexibilité et un contrôle sur la manière dont vos pages web sont accessibles. À l'aide de règles simples mais puissantes, vous pouvez augmenter la sécurité et le bon fonctionnement de votre application. Comme vous pouvez le voir, l'utilisation des attributs dans Nette peut non seulement faciliter votre travail, mais aussi le sécuriser.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/composer.texy b/best-practices/fr/composer.texy
index b1c9478902..b8f9a3e43b 100644
--- a/best-practices/fr/composer.texy
+++ b/best-practices/fr/composer.texy
@@ -280,5 +280,3 @@ Composer est étroitement lié à l'outil de versionnement [Git |https://git-scm
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/creating-editing-form.texy b/best-practices/fr/creating-editing-form.texy
index 572bd23b28..b05616ac5e 100644
--- a/best-practices/fr/creating-editing-form.texy
+++ b/best-practices/fr/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/dynamic-snippets.texy b/best-practices/fr/dynamic-snippets.texy
index 050ba47bc2..d285c2c138 100644
--- a/best-practices/fr/dynamic-snippets.texy
+++ b/best-practices/fr/dynamic-snippets.texy
@@ -171,4 +171,3 @@ Le template de la vue est réduit au minimum nécessaire (et totalement dépourv
Nous avons presque terminé : l'application fonctionnera désormais en AJAX. Ici aussi, nous devons optimiser l'application, car en raison de l'utilisation de Nette Database, lors du traitement du signal, tous les articles sont inutilement chargés depuis la base de données au lieu d'un seul. L'avantage, cependant, est qu'ils ne seront pas rendus, car seul notre composant sera réellement rendu.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/editors-and-tools.texy b/best-practices/fr/editors-and-tools.texy
index 7714a82613..f80342f3fe 100644
--- a/best-practices/fr/editors-and-tools.texy
+++ b/best-practices/fr/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
C'était un outil qui testait l'environnement d'exécution du serveur et informait si (et dans quelle mesure) le framework pouvait être utilisé. Actuellement, Nette peut être utilisé sur n'importe quel serveur disposant de la version minimale requise de PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/form-reuse.texy b/best-practices/fr/form-reuse.texy
index 59ed049764..234ff21ee0 100644
--- a/best-practices/fr/form-reuse.texy
+++ b/best-practices/fr/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/inject-method-attribute.texy b/best-practices/fr/inject-method-attribute.texy
index 7697c7b644..a9896afe31 100644
--- a/best-practices/fr/inject-method-attribute.texy
+++ b/best-practices/fr/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
L'avantage de cette méthode de transmission des dépendances était sa forme d'écriture très concise. Cependant, avec l'arrivée de la [promotion des propriétés du constructeur |https://blog.nette.org/fr/php-8-0-complete-overview-of-news#toc-constructor-property-promotion], il semble plus facile d'utiliser le constructeur.
Inversement, cette méthode souffre des mêmes défauts que la transmission de dépendances aux propriétés en général : nous n'avons aucun contrôle sur les changements dans la variable, et en même temps, la variable devient partie intégrante de l'interface publique de la classe, ce qui n'est pas souhaitable.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/lets-create-contact-form.texy b/best-practices/fr/lets-create-contact-form.texy
index dc14c131b3..081268c0b0 100644
--- a/best-practices/fr/lets-create-contact-form.texy
+++ b/best-practices/fr/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
Et c'est terminé !
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/microsites.texy b/best-practices/fr/microsites.texy
index 370ae19aee..cf0410f4ed 100644
--- a/best-practices/fr/microsites.texy
+++ b/best-practices/fr/microsites.texy
@@ -61,5 +61,3 @@ Pourquoi utiliser Nette pour un microsite ?
- Parfois, la [mise en cache|caching:] peut vous être utile, par exemple si vous téléchargez et affichez des flux.
À notre époque, où la vitesse et l'efficacité sont essentielles, il est important de disposer d'outils qui vous permettent d'obtenir des résultats sans délai inutile. Le framework Nette vous offre exactement cela - un développement rapide, la sécurité et une large gamme d'outils, tels que Tracy et Latte, qui simplifient le processus. Il suffit d'installer quelques paquets Nette et construire un tel microsite devient soudain un jeu d'enfant. Et vous savez qu'aucune faille de sécurité ne se cache nulle part.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/pagination.texy b/best-practices/fr/pagination.texy
index 0a76ce5faf..4c008577ae 100644
--- a/best-practices/fr/pagination.texy
+++ b/best-practices/fr/pagination.texy
@@ -271,4 +271,3 @@ Comme nous n'envoyons plus de Paginator au template, nous modifions la partie af
De cette manière, nous avons implémenté le mécanisme de pagination en utilisant la méthode `page()` de Nette Database Explorer.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/passing-settings-to-presenters.texy b/best-practices/fr/passing-settings-to-presenters.texy
index 13f0d121a7..3aeba172c5 100644
--- a/best-practices/fr/passing-settings-to-presenters.texy
+++ b/best-practices/fr/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/post-links.texy b/best-practices/fr/post-links.texy
index 459ad9de7f..d4c098524f 100644
--- a/best-practices/fr/post-links.texy
+++ b/best-practices/fr/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Cette approche améliore non seulement la sécurité de votre application, mais contribue également au respect des normes et pratiques web correctes. En utilisant les méthodes POST pour les actions modifiant l'état, vous obtiendrez une application plus robuste et plus sûre.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/presenter-traits.texy b/best-practices/fr/presenter-traits.texy
index 36e70f84ab..551c1d5368 100644
--- a/best-practices/fr/presenter-traits.texy
+++ b/best-practices/fr/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/fr/restore-request.texy b/best-practices/fr/restore-request.texy
index 1fbfb55a08..277e87d9ff 100644
--- a/best-practices/fr/restore-request.texy
+++ b/best-practices/fr/restore-request.texy
@@ -60,4 +60,3 @@ Nous passons la clé de la requête sauvegardée à la méthode `restoreRequest(
Cependant, si la clé n'est pas valide (par exemple, elle n'existe plus dans la session), la méthode ne fait rien. L'appel `$this->redirect('Admin:')` suit donc, qui redirige vers `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/@home.texy b/best-practices/hu/@home.texy
index f8e2a8e179..e1ab1cabd8 100644
--- a/best-practices/hu/@home.texy
+++ b/best-practices/hu/@home.texy
@@ -67,6 +67,3 @@ Több száz felvétel a Poslední sobota eseményekről és Nette videók egy he
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/hu/@meta.texy b/best-practices/hu/@meta.texy
new file mode 100644
index 0000000000..9a70856e97
--- /dev/null
+++ b/best-practices/hu/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Útmutatók és eljárások}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/hu/attribute-requires.texy b/best-practices/hu/attribute-requires.texy
index ff446a6ded..819f823943 100644
--- a/best-practices/hu/attribute-requires.texy
+++ b/best-practices/hu/attribute-requires.texy
@@ -175,5 +175,3 @@ Következtetés
-------------
A `#[Requires]` attribútum nagy rugalmasságot és kontrollt ad Önnek afölött, hogyan érhetők el a weboldalai. Egyszerű, de erőteljes szabályok segítségével növelheti alkalmazása biztonságát és helyes működését. Mint láthatja, az attribútumok használata a Nette-ben nemcsak megkönnyítheti a munkáját, hanem biztonságosabbá is teheti.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/composer.texy b/best-practices/hu/composer.texy
index d9b58bc43d..97d7faa75c 100644
--- a/best-practices/hu/composer.texy
+++ b/best-practices/hu/composer.texy
@@ -280,5 +280,3 @@ A Composer szorosan kapcsolódik a [Git |https://git-scm.com] verziókezelő esz
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/creating-editing-form.texy b/best-practices/hu/creating-editing-form.texy
index 0530a75fac..959ed13a7b 100644
--- a/best-practices/hu/creating-editing-form.texy
+++ b/best-practices/hu/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/dynamic-snippets.texy b/best-practices/hu/dynamic-snippets.texy
index 5e847d364c..b6df024d32 100644
--- a/best-practices/hu/dynamic-snippets.texy
+++ b/best-practices/hu/dynamic-snippets.texy
@@ -171,4 +171,3 @@ A view sablonja a szükséges minimumra csökken (és teljesen mentes a snippett
Majdnem készen vagyunk: az alkalmazás mostantól AJAX-osan fog működni. Itt is optimalizálnunk kell az alkalmazást, mert a Nette Database használata miatt a signál feldolgozásakor feleslegesen betöltődik az összes cikk az adatbázisból egy helyett. Előnye azonban, hogy nem kerülnek kirajzolásra, mert valóban csak a mi komponensünk renderelődik.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/editors-and-tools.texy b/best-practices/hu/editors-and-tools.texy
index 26e3bf7980..7104666da7 100644
--- a/best-practices/hu/editors-and-tools.texy
+++ b/best-practices/hu/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Ez egy eszköz volt, amely tesztelte a szerver futási környezetét, és tájékoztatott arról, hogy (és milyen mértékben) lehet használni a keretrendszert. Jelenleg a Nette minden olyan szerveren használható, amely rendelkezik a minimálisan szükséges PHP verzióval.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/form-reuse.texy b/best-practices/hu/form-reuse.texy
index fad3d87058..cbda52b931 100644
--- a/best-practices/hu/form-reuse.texy
+++ b/best-practices/hu/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/inject-method-attribute.texy b/best-practices/hu/inject-method-attribute.texy
index 7939b28085..f36ead2d52 100644
--- a/best-practices/hu/inject-method-attribute.texy
+++ b/best-practices/hu/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Ennek a függőségátadási módnak az előnye a nagyon tömör írásmód volt. Azonban a [constructor property promotion |https://blog.nette.org/hu/php-8-0-complete-overview-of-news#toc-constructor-property-promotion] megjelenésével egyszerűbbnek tűnik a konstruktor használata.
Másrészt ez a módszer ugyanazoktól a hiányosságoktól szenved, mint a függőségek általános property-kbe történő átadása: nincs ellenőrzésünk a változóban bekövetkező változások felett, és ugyanakkor a változó az osztály nyilvános interfészének részévé válik, ami nem kívánatos.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/lets-create-contact-form.texy b/best-practices/hu/lets-create-contact-form.texy
index 8e7c96a90e..3ceafb1f03 100644
--- a/best-practices/hu/lets-create-contact-form.texy
+++ b/best-practices/hu/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
És kész is vagyunk!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/microsites.texy b/best-practices/hu/microsites.texy
index 5aecd10ab3..feb5f639bb 100644
--- a/best-practices/hu/microsites.texy
+++ b/best-practices/hu/microsites.texy
@@ -61,5 +61,3 @@ Miért használjunk Nette-t microsite-hoz?
- Néha hasznos lehet a [gyorsítótárazás |caching:], például ha feedeket tölt le és jelenít meg.
Napjainkban, amikor a sebesség és a hatékonyság kulcsfontosságú, fontos, hogy olyan eszközök álljanak rendelkezésre, amelyek lehetővé teszik az eredmények elérését felesleges késedelem nélkül. A Nette keretrendszer pontosan ezt kínálja - gyors fejlesztést, biztonságot és széles körű eszközöket, mint például a Tracy és a Latte, amelyek egyszerűsítik a folyamatot. Elég telepíteni néhány Nette csomagot, és egy ilyen microsite létrehozása hirtelen gyerekjáték. És tudja, hogy sehol sem rejtőzik biztonsági rés.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/pagination.texy b/best-practices/hu/pagination.texy
index 9b26b4f077..286a369a9b 100644
--- a/best-practices/hu/pagination.texy
+++ b/best-practices/hu/pagination.texy
@@ -271,4 +271,3 @@ Mivel most nem küldünk Paginatort a sablonba, módosítjuk a lapozó linkeket
Ezzel a módszerrel implementáltuk a lapozó mechanizmust Paginator használata nélkül.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/passing-settings-to-presenters.texy b/best-practices/hu/passing-settings-to-presenters.texy
index 3ea0c37194..077d860afd 100644
--- a/best-practices/hu/passing-settings-to-presenters.texy
+++ b/best-practices/hu/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/post-links.texy b/best-practices/hu/post-links.texy
index 011c978da5..8faa625780 100644
--- a/best-practices/hu/post-links.texy
+++ b/best-practices/hu/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Ez a megközelítés nemcsak javítja az alkalmazás biztonságát, hanem hozzájárul a helyes webes szabványok és gyakorlatok betartásához is. A POST metódusok használatával az állapotot megváltoztató műveletekhez robusztusabb és biztonságosabb alkalmazást érhet el.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/presenter-traits.texy b/best-practices/hu/presenter-traits.texy
index decf8f1ca9..a8ec3c6482 100644
--- a/best-practices/hu/presenter-traits.texy
+++ b/best-practices/hu/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/hu/restore-request.texy b/best-practices/hu/restore-request.texy
index 4140a92656..9de22622f4 100644
--- a/best-practices/hu/restore-request.texy
+++ b/best-practices/hu/restore-request.texy
@@ -60,4 +60,3 @@ A `restoreRequest()` metódusnak átadjuk a mentett kérés kulcsát, és az át
Ha azonban a kulcs érvénytelen (például már nem létezik a sessionben), a metódus nem tesz semmit. Ezt követi a `$this->redirect('Admin:')` hívása, amely átirányít az `AdminPresenter`-re.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/it/@home.texy b/best-practices/it/@home.texy
index 9b06375639..7a11feda65 100644
--- a/best-practices/it/@home.texy
+++ b/best-practices/it/@home.texy
@@ -67,6 +67,3 @@ Centinaia di registrazioni dagli Ultimi Sabati e video su Nette si trovano sotto
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/it/@meta.texy b/best-practices/it/@meta.texy
new file mode 100644
index 0000000000..6cd5c59394
--- /dev/null
+++ b/best-practices/it/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Guide e procedure}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/it/attribute-requires.texy b/best-practices/it/attribute-requires.texy
index 6143fe9fde..a2d48132d6 100644
--- a/best-practices/it/attribute-requires.texy
+++ b/best-practices/it/attribute-requires.texy
@@ -175,5 +175,3 @@ Conclusione
-----------
L'attributo `#[Requires]` ti offre grande flessibilità e controllo su come sono accessibili le tue pagine web. Utilizzando regole semplici ma potenti, puoi aumentare la sicurezza e il corretto funzionamento della tua applicazione. Come vedi, l'uso degli attributi in Nette può non solo facilitare il tuo lavoro, ma anche renderlo più sicuro.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/composer.texy b/best-practices/it/composer.texy
index 4335ab8471..8eb011319e 100644
--- a/best-practices/it/composer.texy
+++ b/best-practices/it/composer.texy
@@ -280,5 +280,3 @@ Composer è strettamente legato allo strumento di versioning [Git |https://git-s
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/creating-editing-form.texy b/best-practices/it/creating-editing-form.texy
index e4a187d491..7a5868873c 100644
--- a/best-practices/it/creating-editing-form.texy
+++ b/best-practices/it/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/it/dynamic-snippets.texy b/best-practices/it/dynamic-snippets.texy
index daaa6ab6e9..e2c34a8080 100644
--- a/best-practices/it/dynamic-snippets.texy
+++ b/best-practices/it/dynamic-snippets.texy
@@ -171,4 +171,3 @@ Il template della vista si riduce al minimo indispensabile (e completamente priv
Abbiamo quasi finito: l'applicazione ora funzionerà in modo AJAX. Anche qui dovremo ottimizzare l'applicazione, perché a causa dell'uso di Nette Database, durante l'elaborazione del segnale vengono caricati inutilmente tutti gli articoli dal database invece di uno solo. Il vantaggio, tuttavia, è che non verranno renderizzati, perché verrà renderizzato effettivamente solo il nostro componente.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/it/editors-and-tools.texy b/best-practices/it/editors-and-tools.texy
index 2e7f9c57b2..9386b93f8e 100644
--- a/best-practices/it/editors-and-tools.texy
+++ b/best-practices/it/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Era uno strumento che testava l'ambiente di runtime del server e informava se (e in che misura) fosse possibile utilizzare il framework. Attualmente, Nette può essere utilizzato su qualsiasi server che abbia la versione minima richiesta di PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/form-reuse.texy b/best-practices/it/form-reuse.texy
index f277f02e24..ccd4423502 100644
--- a/best-practices/it/form-reuse.texy
+++ b/best-practices/it/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/inject-method-attribute.texy b/best-practices/it/inject-method-attribute.texy
index 28a15600fc..d031886e4c 100644
--- a/best-practices/it/inject-method-attribute.texy
+++ b/best-practices/it/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Il vantaggio di questo modo di passare le dipendenze era la forma di scrittura molto concisa. Tuttavia, con l'avvento della [constructor property promotion |https://blog.nette.org/it/php-8-0-complete-overview-of-news#toc-constructor-property-promotion], sembra più facile utilizzare il costruttore.
Al contrario, questo metodo soffre degli stessi svantaggi del passaggio delle dipendenze alle proprietà in generale: non abbiamo controllo sulle modifiche nella variabile e allo stesso tempo la variabile diventa parte dell'interfaccia pubblica della classe, il che è indesiderabile.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/lets-create-contact-form.texy b/best-practices/it/lets-create-contact-form.texy
index 2375125052..5b7992de4b 100644
--- a/best-practices/it/lets-create-contact-form.texy
+++ b/best-practices/it/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
Ed è fatto!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/microsites.texy b/best-practices/it/microsites.texy
index f53450bef6..1efd628d35 100644
--- a/best-practices/it/microsites.texy
+++ b/best-practices/it/microsites.texy
@@ -61,5 +61,3 @@ Perché usare Nette per un microsito?
- A volte potrebbe esservi utile il [caching|caching:], ad esempio se scaricate e visualizzate feed.
Al giorno d'oggi, quando la velocità e l'efficienza sono fondamentali, è importante avere strumenti che vi permettano di ottenere risultati senza inutili ritardi. Nette framework vi offre proprio questo: sviluppo rapido, sicurezza e un'ampia gamma di strumenti, come Tracy e Latte, che semplificano il processo. Basta installare un paio di pacchetti Nette e costruire un tale microsito diventa improvvisamente un gioco da ragazzi. E sapete che non si nasconde nessuna falla di sicurezza da nessuna parte.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/pagination.texy b/best-practices/it/pagination.texy
index 14015254bc..1f61f6b633 100644
--- a/best-practices/it/pagination.texy
+++ b/best-practices/it/pagination.texy
@@ -271,4 +271,3 @@ Poiché ora non inviamo Paginator al template, modifichiamo la parte che visuali
In questo modo abbiamo implementato il meccanismo di paginazione senza l'uso di Paginator.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/it/passing-settings-to-presenters.texy b/best-practices/it/passing-settings-to-presenters.texy
index 71706b7fc5..61357ccd6b 100644
--- a/best-practices/it/passing-settings-to-presenters.texy
+++ b/best-practices/it/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/post-links.texy b/best-practices/it/post-links.texy
index 90036d98d7..7eccd96552 100644
--- a/best-practices/it/post-links.texy
+++ b/best-practices/it/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Questo approccio non solo migliora la sicurezza della vostra applicazione, ma contribuisce anche al rispetto degli standard e delle pratiche web corrette. Utilizzando i metodi POST per le azioni che modificano lo stato, otterrete un'applicazione più robusta e sicura.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/presenter-traits.texy b/best-practices/it/presenter-traits.texy
index da2b2d0e07..9fa07a6483 100644
--- a/best-practices/it/presenter-traits.texy
+++ b/best-practices/it/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/it/restore-request.texy b/best-practices/it/restore-request.texy
index 54062ba823..abb5ee93e8 100644
--- a/best-practices/it/restore-request.texy
+++ b/best-practices/it/restore-request.texy
@@ -60,4 +60,3 @@ Al metodo `restoreRequest()` passiamo la chiave della richiesta salvata e questo
Tuttavia, se la chiave non è valida (ad esempio, non esiste più nella sessione), il metodo non fa nulla. Segue quindi la chiamata `$this->redirect('Admin:')`, che reindirizza a `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ja/@home.texy b/best-practices/ja/@home.texy
index f7ac5de5b3..eab0e604fe 100644
--- a/best-practices/ja/@home.texy
+++ b/best-practices/ja/@home.texy
@@ -67,6 +67,3 @@ Poslední soboty の何百もの録画と Nette に関するビデオは、「Ne
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/ja/@meta.texy b/best-practices/ja/@meta.texy
new file mode 100644
index 0000000000..faa40c5409
--- /dev/null
+++ b/best-practices/ja/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: ガイドとベストプラクティス}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/ja/attribute-requires.texy b/best-practices/ja/attribute-requires.texy
index 8825e3110a..5e374df7a0 100644
--- a/best-practices/ja/attribute-requires.texy
+++ b/best-practices/ja/attribute-requires.texy
@@ -175,5 +175,3 @@ class ApiPresenter extends Nette\Application\UI\Presenter
---
`#[Requires]` 属性は、Web サイトへのアクセス方法について大きな柔軟性とコントロールを提供します。シンプルでありながら強力なルールを使用して、アプリケーションのセキュリティと適切な動作を向上させることができます。ご覧のとおり、Nette で属性を使用すると、作業が容易になるだけでなく、安全にもなります。
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ja/composer.texy b/best-practices/ja/composer.texy
index 286fcd49f1..afd0df7f16 100644
--- a/best-practices/ja/composer.texy
+++ b/best-practices/ja/composer.texy
@@ -280,5 +280,3 @@ Composerはバージョン管理ツール [Git |https://git-scm.com] と密接
```shell
composer -g config preferred-install dist
```
-
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/creating-editing-form.texy b/best-practices/ja/creating-editing-form.texy
index a4176f8136..806cea4a84 100644
--- a/best-practices/ja/creating-editing-form.texy
+++ b/best-practices/ja/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/dynamic-snippets.texy b/best-practices/ja/dynamic-snippets.texy
index edb6c61c47..eae6f47e34 100644
--- a/best-practices/ja/dynamic-snippets.texy
+++ b/best-practices/ja/dynamic-snippets.texy
@@ -171,4 +171,3 @@ protected function createComponentLikeControl()
ほぼ完了です:アプリケーションはこれでAJAXで動作します。ここでもアプリケーションを最適化する必要があります。なぜなら、Nette Databaseを使用しているため、シグナルの処理中にデータベースから1つではなく、すべての記事が不必要にロードされるからです。しかし、利点は、実際に私たちのコンポーネントだけがレンダリングされるため、それらの描画が行われないことです。
{{priority: -1}}
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/editors-and-tools.texy b/best-practices/ja/editors-and-tools.texy
index a839358bd8..36e72f6ea2 100644
--- a/best-practices/ja/editors-and-tools.texy
+++ b/best-practices/ja/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
これは、サーバーの実行環境をテストし、フレームワークを使用できるかどうか(およびどの程度まで)を通知するツールでした。現在、Netteは最小限必要なPHPバージョンを持つすべてのサーバーで使用できます。
-
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/form-reuse.texy b/best-practices/ja/form-reuse.texy
index 7b2562bb8f..ed1fa5507b 100644
--- a/best-practices/ja/form-reuse.texy
+++ b/best-practices/ja/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/inject-method-attribute.texy b/best-practices/ja/inject-method-attribute.texy
index 66d01a14a1..7e85e1e486 100644
--- a/best-practices/ja/inject-method-attribute.texy
+++ b/best-practices/ja/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
この依存関係の受け渡し方法の利点は、非常に簡潔な記述形式でした。しかし、[コンストラクタプロパティプロモーション |https://blog.nette.org/ja/php-8-0-new-features-overview#toc-constructor-property-promotion] の登場により、コンストラクタを使用する方が簡単に見えます。
逆に、この方法は、一般的にプロパティへの依存関係の受け渡しと同じ欠点があります:変数内の変更を制御できず、同時に変数がクラスのパブリックインターフェースの一部となり、これは望ましくありません。
-
-
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/lets-create-contact-form.texy b/best-practices/ja/lets-create-contact-form.texy
index a342052a76..e810ca3a2b 100644
--- a/best-practices/ja/lets-create-contact-form.texy
+++ b/best-practices/ja/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
これで完了です!
-
-
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/microsites.texy b/best-practices/ja/microsites.texy
index 0c11688bc0..f534524da8 100644
--- a/best-practices/ja/microsites.texy
+++ b/best-practices/ja/microsites.texy
@@ -61,5 +61,3 @@ $container->getByType(Nette\Application\Application::class)->run();
- たとえばフィードを取得して表示する場合など、[キャッシュ|caching:] が役立つことがあります。
速度と効率が鍵となる今日の世界では、不必要な遅延なしに結果を達成できるツールを持つことが重要です。Nette frameworkはまさにそれを提供します - 迅速な開発、セキュリティ、そしてプロセスを簡素化するTracyやLatteなどの幅広いツール。いくつかのNetteパッケージをインストールするだけで、このようなマイクロサイトを構築するのは突然非常に簡単になります。そして、どこにもセキュリティホールが隠れていないことを知っています。
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ja/pagination.texy b/best-practices/ja/pagination.texy
index 7edca052f3..c2524004bd 100644
--- a/best-practices/ja/pagination.texy
+++ b/best-practices/ja/pagination.texy
@@ -271,4 +271,3 @@ class HomePresenter extends Nette\Application\UI\Presenter
この方法で、Paginatorを使用せずにページネーションメカニズムを実装しました。
{{priority: -1}}
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/passing-settings-to-presenters.texy b/best-practices/ja/passing-settings-to-presenters.texy
index 208ec25aa8..78fcc70158 100644
--- a/best-practices/ja/passing-settings-to-presenters.texy
+++ b/best-practices/ja/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/post-links.texy b/best-practices/ja/post-links.texy
index a1be3374f0..2d4877f097 100644
--- a/best-practices/ja/post-links.texy
+++ b/best-practices/ja/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
このアプローチは、アプリケーションのセキュリティを向上させるだけでなく、正しいWeb標準と実践の遵守にも貢献します。状態を変更するアクションにPOSTメソッドを利用することで、より堅牢で安全なアプリケーションを実現できます。
-
-
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/presenter-traits.texy b/best-practices/ja/presenter-traits.texy
index ccaf3711c4..3410b8424f 100644
--- a/best-practices/ja/presenter-traits.texy
+++ b/best-practices/ja/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/ja/restore-request.texy b/best-practices/ja/restore-request.texy
index 4ae6811f06..6a17b77503 100644
--- a/best-practices/ja/restore-request.texy
+++ b/best-practices/ja/restore-request.texy
@@ -60,4 +60,3 @@ class SignPresenter extends Nette\Application\UI\Presenter
ただし、キーが無効な場合(たとえば、セッションに存在しなくなった場合)、メソッドは何も行いません。したがって、`AdminPresenter` にリダイレクトする `$this->redirect('Admin:')` の呼び出しが続きます。
{{priority: -1}}
-{{sitename: ベストプラクティス}}
diff --git a/best-practices/pl/@home.texy b/best-practices/pl/@home.texy
index 825d540412..64470576e1 100644
--- a/best-practices/pl/@home.texy
+++ b/best-practices/pl/@home.texy
@@ -67,6 +67,3 @@ Setki nagrań z Posledních sobot i filmów o Nette znajdziesz pod jednym dachem
-
-{{sitename: Dobre praktyki}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/pl/@meta.texy b/best-practices/pl/@meta.texy
new file mode 100644
index 0000000000..28fbec9e34
--- /dev/null
+++ b/best-practices/pl/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Przewodniki i dobre praktyki}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/pl/attribute-requires.texy b/best-practices/pl/attribute-requires.texy
index 515bf68c11..750a41a034 100644
--- a/best-practices/pl/attribute-requires.texy
+++ b/best-practices/pl/attribute-requires.texy
@@ -175,5 +175,3 @@ Zakończenie
-----------
Atrybut `#[Requires]` daje Ci dużą elastyczność i kontrolę nad tym, jak dostępne są Twoje strony internetowe. Za pomocą prostych, ale potężnych reguł możesz zwiększyć bezpieczeństwo i prawidłowe funkcjonowanie Twojej aplikacji. Jak widzisz, użycie atrybutów w Nette może Twoją pracę nie tylko ułatwić, ale i zabezpieczyć.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/composer.texy b/best-practices/pl/composer.texy
index f9dbf766ee..f8ccf099f8 100644
--- a/best-practices/pl/composer.texy
+++ b/best-practices/pl/composer.texy
@@ -280,5 +280,3 @@ Composer jest ściśle powiązany z narzędziem do wersjonowania [Git |https://g
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/creating-editing-form.texy b/best-practices/pl/creating-editing-form.texy
index cf84a444b2..d5aeaa3c1c 100644
--- a/best-practices/pl/creating-editing-form.texy
+++ b/best-practices/pl/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/dynamic-snippets.texy b/best-practices/pl/dynamic-snippets.texy
index db88b1316a..67ac6ba7c0 100644
--- a/best-practices/pl/dynamic-snippets.texy
+++ b/best-practices/pl/dynamic-snippets.texy
@@ -171,4 +171,3 @@ Szablon widoku zmniejszy się do niezbędnego minimum (i całkowicie pozbawiony
Mamy prawie gotowe: aplikacja teraz będzie działać AJAXowo. Również tutaj czeka nas optymalizacja aplikacji, ponieważ ze względu na użycie Nette Database podczas przetwarzania sygnału niepotrzebnie ładowane są wszystkie artykuły z bazy danych zamiast jednego. Zaletą jest jednak to, że nie dojdzie do ich renderowania, ponieważ wyrenderuje się rzeczywiście tylko nasz komponent.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/editors-and-tools.texy b/best-practices/pl/editors-and-tools.texy
index 26b4ed4286..7488231779 100644
--- a/best-practices/pl/editors-and-tools.texy
+++ b/best-practices/pl/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Było to narzędzie, które testowało środowisko uruchomieniowe serwera i informowało, czy (i w jakim stopniu) można używać frameworka. Obecnie Nette można używać na każdym serwerze, który ma minimalną wymaganą wersję PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/form-reuse.texy b/best-practices/pl/form-reuse.texy
index 7a65265c1d..c4b5179419 100644
--- a/best-practices/pl/form-reuse.texy
+++ b/best-practices/pl/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/inject-method-attribute.texy b/best-practices/pl/inject-method-attribute.texy
index 3c4c88ec33..a5889d2155 100644
--- a/best-practices/pl/inject-method-attribute.texy
+++ b/best-practices/pl/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Zaletą tego sposobu przekazywania zależności była bardzo oszczędna forma zapisu. Jednak wraz z pojawieniem się [constructor property promotion |https://blog.nette.org/pl/php-8-0-complete-overview-of-news#toc-constructor-property-promotion] wydaje się łatwiejsze użycie konstruktora.
Z drugiej strony, ten sposób cierpi na te same wady, co przekazywanie zależności do właściwości ogólnie: nie mamy kontroli nad zmianami w zmiennej, a jednocześnie zmienna staje się częścią publicznego interfejsu klasy, co jest niepożądane.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/lets-create-contact-form.texy b/best-practices/pl/lets-create-contact-form.texy
index 6f8c5a43ef..4381796a10 100644
--- a/best-practices/pl/lets-create-contact-form.texy
+++ b/best-practices/pl/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
I gotowe!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/microsites.texy b/best-practices/pl/microsites.texy
index 332bef3ec8..72b1666dae 100644
--- a/best-practices/pl/microsites.texy
+++ b/best-practices/pl/microsites.texy
@@ -61,5 +61,3 @@ Dlaczego używać Nette do mikrostroń?
- Czasami może przydać się [cache|caching:], na przykład jeśli pobierasz i wyświetlasz feedy.
W dzisiejszych czasach, gdy szybkość i efektywność są kluczowe, ważne jest posiadanie narzędzi, które pozwolą Ci osiągnąć wyniki bez zbędnego opóźnienia. Nette framework oferuje właśnie to - szybki rozwój, bezpieczeństwo i szeroką gamę narzędzi, takich jak Tracy i Latte, które upraszczają proces. Wystarczy zainstalować kilka pakietów Nette, a zbudowanie takiej mikrostroń staje się nagle dziecinnie proste. I wiesz, że nigdzie nie kryje się żadna dziura bezpieczeństwa.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/pagination.texy b/best-practices/pl/pagination.texy
index 44ca51c7d2..b79dc18dce 100644
--- a/best-practices/pl/pagination.texy
+++ b/best-practices/pl/pagination.texy
@@ -271,4 +271,3 @@ Ponieważ do szablonu teraz nie wysyłamy obiektu Paginator, zmodyfikujemy czę
W ten sposób zaimplementowaliśmy mechanizm paginacji bez użycia Paginatora.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/passing-settings-to-presenters.texy b/best-practices/pl/passing-settings-to-presenters.texy
index 73f093dd82..2c8ef4b1f7 100644
--- a/best-practices/pl/passing-settings-to-presenters.texy
+++ b/best-practices/pl/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/post-links.texy b/best-practices/pl/post-links.texy
index 004ed6747e..257edf12d6 100644
--- a/best-practices/pl/post-links.texy
+++ b/best-practices/pl/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Takie podejście nie tylko poprawia bezpieczeństwo Twojej aplikacji, ale także przyczynia się do przestrzegania prawidłowych standardów i praktyk internetowych. Wykorzystując metody POST do akcji zmieniających stan, osiągniesz bardziej solidną i bezpieczniejszą aplikację.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/presenter-traits.texy b/best-practices/pl/presenter-traits.texy
index 3731b2f7ff..d819871207 100644
--- a/best-practices/pl/presenter-traits.texy
+++ b/best-practices/pl/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pl/restore-request.texy b/best-practices/pl/restore-request.texy
index 47455b6c85..4d279ee9bb 100644
--- a/best-practices/pl/restore-request.texy
+++ b/best-practices/pl/restore-request.texy
@@ -60,4 +60,3 @@ Metodzie `restoreRequest()` przekazujemy klucz zapisanego żądania, a ona przek
Jeśli jednak klucz jest nieprawidłowy (na przykład już nie istnieje w sesji), metoda nic nie robi. Następuje więc wywołanie `$this->redirect('Admin:')`, które przekierowuje na `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/@home.texy b/best-practices/pt/@home.texy
index 79691787b7..ff77ce2b7f 100644
--- a/best-practices/pt/@home.texy
+++ b/best-practices/pt/@home.texy
@@ -67,6 +67,3 @@ Centenas de gravações dos Últimos Sábados e vídeos sobre Nette podem ser en
-
-{{sitename: Melhores Práticas}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/pt/@meta.texy b/best-practices/pt/@meta.texy
new file mode 100644
index 0000000000..1bf3200c6f
--- /dev/null
+++ b/best-practices/pt/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Guias e melhores práticas}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/pt/attribute-requires.texy b/best-practices/pt/attribute-requires.texy
index 8b0ba39018..e128fa61b9 100644
--- a/best-practices/pt/attribute-requires.texy
+++ b/best-practices/pt/attribute-requires.texy
@@ -175,5 +175,3 @@ Conclusão
---------
O atributo `#[Requires]` oferece grande flexibilidade e controle sobre como suas páginas web são acessíveis. Usando regras simples, mas poderosas, você pode aumentar a segurança e o funcionamento correto da sua aplicação. Como você pode ver, o uso de atributos no Nette pode não apenas facilitar seu trabalho, mas também torná-lo mais seguro.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/composer.texy b/best-practices/pt/composer.texy
index 39f288c7b9..0bbb245278 100644
--- a/best-practices/pt/composer.texy
+++ b/best-practices/pt/composer.texy
@@ -280,5 +280,3 @@ O Composer está intimamente ligado à ferramenta de versionamento [Git |https:/
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/creating-editing-form.texy b/best-practices/pt/creating-editing-form.texy
index ca47894989..c08c92a039 100644
--- a/best-practices/pt/creating-editing-form.texy
+++ b/best-practices/pt/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/dynamic-snippets.texy b/best-practices/pt/dynamic-snippets.texy
index 7ca7f1e526..a77d207b02 100644
--- a/best-practices/pt/dynamic-snippets.texy
+++ b/best-practices/pt/dynamic-snippets.texy
@@ -171,4 +171,3 @@ O template da view será reduzido ao mínimo necessário (e completamente livre
Estamos quase lá: a aplicação agora funcionará com AJAX. Aqui também teremos que otimizar a aplicação, porque devido ao uso do Nette Database, ao processar o sinal, todos os artigos são carregados desnecessariamente do banco de dados em vez de apenas um. A vantagem, no entanto, é que eles não serão renderizados, pois apenas nosso componente será renderizado.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/editors-and-tools.texy b/best-practices/pt/editors-and-tools.texy
index 410005d8eb..6d841136f7 100644
--- a/best-practices/pt/editors-and-tools.texy
+++ b/best-practices/pt/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Era uma ferramenta que testava o ambiente de execução do servidor e informava se (e em que medida) o framework poderia ser usado. Atualmente, o Nette pode ser usado em qualquer servidor que tenha a versão mínima exigida do PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/form-reuse.texy b/best-practices/pt/form-reuse.texy
index ec962c3985..a1c88ae4c5 100644
--- a/best-practices/pt/form-reuse.texy
+++ b/best-practices/pt/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/inject-method-attribute.texy b/best-practices/pt/inject-method-attribute.texy
index 97af16f165..c5b05410c2 100644
--- a/best-practices/pt/inject-method-attribute.texy
+++ b/best-practices/pt/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
A vantagem dessa forma de passar dependências era a forma de escrita muito concisa. No entanto, com a chegada da [promoção de propriedades do construtor |https://blog.nette.org/pt/php-8-0-complete-overview-of-news#toc-constructor-property-promotion], parece mais fácil usar o construtor.
Por outro lado, essa forma sofre das mesmas desvantagens que a passagem de dependências para propriedades em geral: não temos controle sobre as alterações na variável e, ao mesmo tempo, a variável se torna parte da interface pública da classe, o que é indesejável.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/lets-create-contact-form.texy b/best-practices/pt/lets-create-contact-form.texy
index 147d68034f..f75fa749a8 100644
--- a/best-practices/pt/lets-create-contact-form.texy
+++ b/best-practices/pt/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
E está pronto!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/microsites.texy b/best-practices/pt/microsites.texy
index c4194f071c..92abd0db15 100644
--- a/best-practices/pt/microsites.texy
+++ b/best-practices/pt/microsites.texy
@@ -61,5 +61,3 @@ Por que usar Nette para microsites?
- Às vezes, pode ser útil usar [cache|caching:], por exemplo, se você baixa e exibe feeds.
Nos dias de hoje, onde a velocidade e a eficiência são cruciais, é importante ter ferramentas que permitam alcançar resultados sem atrasos desnecessários. O framework Nette oferece exatamente isso - desenvolvimento rápido, segurança e uma ampla gama de ferramentas, como Tracy e Latte, que simplificam o processo. Basta instalar alguns pacotes Nette e construir tal microsite torna-se de repente uma brincadeira de criança. E você sabe que não há nenhuma falha de segurança escondida em lugar nenhum.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/pagination.texy b/best-practices/pt/pagination.texy
index 0af3597abe..a1ec4b1351 100644
--- a/best-practices/pt/pagination.texy
+++ b/best-practices/pt/pagination.texy
@@ -271,4 +271,3 @@ Como agora não enviamos o Paginator para o template, modificamos a parte que ex
Desta forma, implementamos o mecanismo de paginação usando o Nette Database Explorer sem a necessidade explícita do Paginator.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/passing-settings-to-presenters.texy b/best-practices/pt/passing-settings-to-presenters.texy
index 95355f94f5..a9f8a66798 100644
--- a/best-practices/pt/passing-settings-to-presenters.texy
+++ b/best-practices/pt/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/post-links.texy b/best-practices/pt/post-links.texy
index ed748d935e..b1ddb720ee 100644
--- a/best-practices/pt/post-links.texy
+++ b/best-practices/pt/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Esta abordagem não só melhora a segurança da sua aplicação, mas também contribui para a adesão aos padrões e práticas corretas da web. Ao utilizar métodos POST para ações que alteram o estado, você alcançará uma aplicação mais robusta e segura.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/presenter-traits.texy b/best-practices/pt/presenter-traits.texy
index bc0e12749f..0a6ad31278 100644
--- a/best-practices/pt/presenter-traits.texy
+++ b/best-practices/pt/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/pt/restore-request.texy b/best-practices/pt/restore-request.texy
index 520e15b4e5..c46f2ecb8d 100644
--- a/best-practices/pt/restore-request.texy
+++ b/best-practices/pt/restore-request.texy
@@ -60,4 +60,3 @@ Passamos a chave da requisição salva para o método `restoreRequest()` e ele r
No entanto, se a chave for inválida (por exemplo, não existir mais na sessão), o método não faz nada. Segue-se então a chamada `$this->redirect('Admin:')`, que redireciona para `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/@home.texy b/best-practices/ro/@home.texy
index 580325e2c3..a742e5d015 100644
--- a/best-practices/ro/@home.texy
+++ b/best-practices/ro/@home.texy
@@ -67,6 +67,3 @@ Sute de înregistrări de la Ultimele Sâmbete și videoclipuri despre Nette pot
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/ro/@meta.texy b/best-practices/ro/@meta.texy
new file mode 100644
index 0000000000..738844dc28
--- /dev/null
+++ b/best-practices/ro/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Tutoriale și proceduri}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/ro/attribute-requires.texy b/best-practices/ro/attribute-requires.texy
index ce24c65df6..26bc6f5e2b 100644
--- a/best-practices/ro/attribute-requires.texy
+++ b/best-practices/ro/attribute-requires.texy
@@ -175,5 +175,3 @@ Concluzie
---------
Atributul `#[Requires]` vă oferă o mare flexibilitate și control asupra modului în care paginile dvs. web sunt accesibile. Folosind reguli simple, dar puternice, puteți crește securitatea și funcționarea corectă a aplicației dvs. După cum vedeți, utilizarea atributelor în Nette vă poate nu numai ușura munca, ci și securiza.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/composer.texy b/best-practices/ro/composer.texy
index 631d9e2a54..2e63994768 100644
--- a/best-practices/ro/composer.texy
+++ b/best-practices/ro/composer.texy
@@ -280,5 +280,3 @@ Composer este strâns legat de instrumentul de versionare [Git |https://git-scm.
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/creating-editing-form.texy b/best-practices/ro/creating-editing-form.texy
index af2a3d0887..8c58fc221a 100644
--- a/best-practices/ro/creating-editing-form.texy
+++ b/best-practices/ro/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/dynamic-snippets.texy b/best-practices/ro/dynamic-snippets.texy
index 02d427c11f..f6879f7488 100644
--- a/best-practices/ro/dynamic-snippets.texy
+++ b/best-practices/ro/dynamic-snippets.texy
@@ -171,4 +171,3 @@ protected function createComponentLikeControl()
Aproape am terminat: aplicația va funcționa acum cu AJAX. Și aici va trebui să optimizăm aplicația, deoarece, datorită utilizării Nette Database, la procesarea semnalului se încarcă inutil toate articolele din baza de date în loc de unul singur. Avantajul este însă că acestea nu vor fi redate, deoarece se va reda efectiv doar componenta noastră.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/editors-and-tools.texy b/best-practices/ro/editors-and-tools.texy
index 602f1411ce..7c44d258a6 100644
--- a/best-practices/ro/editors-and-tools.texy
+++ b/best-practices/ro/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Acesta a fost un instrument care testa mediul de rulare al serverului și informa dacă (și în ce măsură) framework-ul poate fi utilizat. În prezent, Nette poate fi utilizat pe orice server care are versiunea minimă necesară de PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/form-reuse.texy b/best-practices/ro/form-reuse.texy
index a34327c36a..20b7c45804 100644
--- a/best-practices/ro/form-reuse.texy
+++ b/best-practices/ro/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/inject-method-attribute.texy b/best-practices/ro/inject-method-attribute.texy
index 6520005009..0479b38c22 100644
--- a/best-practices/ro/inject-method-attribute.texy
+++ b/best-practices/ro/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Avantajul acestei metode de transmitere a dependențelor a fost forma foarte concisă a scrierii. Cu toate acestea, odată cu apariția [constructor property promotion |https://blog.nette.org/ro/php-8-0-complete-overview-of-news#toc-constructor-property-promotion], pare mai ușor să folosești constructorul.
Pe de altă parte, această metodă suferă de aceleași neajunsuri ca și transmiterea dependențelor către proprietăți în general: nu avem control asupra modificărilor din variabilă și, în același timp, variabila devine parte a interfeței publice a clasei, ceea ce este nedorit.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/lets-create-contact-form.texy b/best-practices/ro/lets-create-contact-form.texy
index db79dd3f3c..9ae4c05523 100644
--- a/best-practices/ro/lets-create-contact-form.texy
+++ b/best-practices/ro/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
Și am terminat!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/microsites.texy b/best-practices/ro/microsites.texy
index 8170575e64..6c4441df8b 100644
--- a/best-practices/ro/microsites.texy
+++ b/best-practices/ro/microsites.texy
@@ -61,5 +61,3 @@ De ce să folosiți Nette pentru microsite-uri?
- Uneori vă poate fi utilă [cache-uirea |caching:], de exemplu dacă descărcați și afișați feed-uri.
În zilele noastre, când viteza și eficiența sunt esențiale, este important să aveți instrumente care vă permit să obțineți rezultate fără întârzieri inutile. Nette framework vă oferă exact asta - dezvoltare rapidă, securitate și o gamă largă de instrumente, cum ar fi Tracy și Latte, care simplifică procesul. Este suficient să instalați câteva pachete Nette și construirea unui astfel de microsite devine brusc o joacă de copii. Și știți că nu se ascunde nicio gaură de securitate nicăieri.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/pagination.texy b/best-practices/ro/pagination.texy
index 8568297eb3..fe8b8e2114 100644
--- a/best-practices/ro/pagination.texy
+++ b/best-practices/ro/pagination.texy
@@ -271,4 +271,3 @@ Deoarece acum nu trimitem `Paginator` către șablon, modificăm partea care afi
În acest mod am implementat mecanismul de paginare fără utilizarea Paginatorului.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/passing-settings-to-presenters.texy b/best-practices/ro/passing-settings-to-presenters.texy
index dfc853fa13..0b0e2883ee 100644
--- a/best-practices/ro/passing-settings-to-presenters.texy
+++ b/best-practices/ro/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/post-links.texy b/best-practices/ro/post-links.texy
index 27676fcd2d..449a9de1c5 100644
--- a/best-practices/ro/post-links.texy
+++ b/best-practices/ro/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Această abordare nu numai că îmbunătățește securitatea aplicației dvs., dar contribuie și la respectarea standardelor și practicilor web corecte. Prin utilizarea metodelor POST pentru acțiunile care modifică starea, veți obține o aplicație mai robustă și mai sigură.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/presenter-traits.texy b/best-practices/ro/presenter-traits.texy
index db57366033..a074c21292 100644
--- a/best-practices/ro/presenter-traits.texy
+++ b/best-practices/ro/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ro/restore-request.texy b/best-practices/ro/restore-request.texy
index 3071c05c24..a8cee5857c 100644
--- a/best-practices/ro/restore-request.texy
+++ b/best-practices/ro/restore-request.texy
@@ -60,4 +60,3 @@ Metodei `restoreRequest()` îi transmitem cheia cererii salvate și aceasta redi
Dacă însă cheia este invalidă (de exemplu, nu mai există în sesiune), metoda nu face nimic. Urmează deci apelul `$this->redirect('Admin:')`, care redirecționează către `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/@home.texy b/best-practices/ru/@home.texy
index 2f6fc4121c..1ea3ce7e1e 100644
--- a/best-practices/ru/@home.texy
+++ b/best-practices/ru/@home.texy
@@ -67,6 +67,3 @@
-
-{{sitename: Лучшие практики}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/ru/@meta.texy b/best-practices/ru/@meta.texy
new file mode 100644
index 0000000000..6463960eed
--- /dev/null
+++ b/best-practices/ru/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Руководства и лучшие практики}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/ru/attribute-requires.texy b/best-practices/ru/attribute-requires.texy
index 99854f0bfe..8fafce3e80 100644
--- a/best-practices/ru/attribute-requires.texy
+++ b/best-practices/ru/attribute-requires.texy
@@ -175,5 +175,3 @@ class ApiPresenter extends Nette\Application\UI\Presenter
----------
Атрибут `#[Requires]` дает вам большую гибкость и контроль над тем, как доступны ваши веб-страницы. С помощью простых, но мощных правил вы можете повысить безопасность и правильное функционирование вашего приложения. Как видите, использование атрибутов в Nette может не только упростить вашу работу, но и обезопасить ее.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/composer.texy b/best-practices/ru/composer.texy
index bc2c64c211..b8f63ccad6 100644
--- a/best-practices/ru/composer.texy
+++ b/best-practices/ru/composer.texy
@@ -280,5 +280,3 @@ Composer тесно связан с инструментом версионир
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/creating-editing-form.texy b/best-practices/ru/creating-editing-form.texy
index 259d1c436c..bc6b5b84e1 100644
--- a/best-practices/ru/creating-editing-form.texy
+++ b/best-practices/ru/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/dynamic-snippets.texy b/best-practices/ru/dynamic-snippets.texy
index 20badb7eee..30a58602e3 100644
--- a/best-practices/ru/dynamic-snippets.texy
+++ b/best-practices/ru/dynamic-snippets.texy
@@ -171,4 +171,3 @@ protected function createComponentLikeControl()
Почти готово: приложение теперь будет работать с AJAX. Здесь нас также ждет оптимизация приложения, потому что из-за использования Nette Database при обработке сигнала из базы данных излишне загружаются все статьи вместо одной. Преимуществом, однако, является то, что их отрисовка не происходит, потому что рендерится действительно только наш компонент.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/editors-and-tools.texy b/best-practices/ru/editors-and-tools.texy
index 97a6642ccb..7508f40017 100644
--- a/best-practices/ru/editors-and-tools.texy
+++ b/best-practices/ru/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Это был инструмент, который тестировал среду выполнения сервера и сообщал, можно ли (и в какой степени) использовать фреймворк. В настоящее время Nette можно использовать на любом сервере, имеющем минимально требуемую версию PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/form-reuse.texy b/best-practices/ru/form-reuse.texy
index 89ed9eda31..2c8dd3114c 100644
--- a/best-practices/ru/form-reuse.texy
+++ b/best-practices/ru/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/inject-method-attribute.texy b/best-practices/ru/inject-method-attribute.texy
index d8da611af2..689ddbfa3c 100644
--- a/best-practices/ru/inject-method-attribute.texy
+++ b/best-practices/ru/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Преимуществом этого способа передачи зависимостей была очень лаконичная форма записи. Однако с появлением [constructor property promotion |https://blog.nette.org/ru/php-8-0-complete-overview-of-news#toc-constructor-property-promotion] кажется проще использовать конструктор.
Напротив, этот способ страдает теми же недостатками, что и передача зависимости в свойства в целом: у нас нет контроля над изменениями в переменной, и в то же время переменная становится частью публичного интерфейса класса, что нежелательно.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/lets-create-contact-form.texy b/best-practices/ru/lets-create-contact-form.texy
index c8906b0fb1..981a38df9b 100644
--- a/best-practices/ru/lets-create-contact-form.texy
+++ b/best-practices/ru/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
И готово!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/microsites.texy b/best-practices/ru/microsites.texy
index f1519cf032..c82e82b71a 100644
--- a/best-practices/ru/microsites.texy
+++ b/best-practices/ru/microsites.texy
@@ -61,5 +61,3 @@ PHP-код в `index.php` сначала [подготавливает сред
- Иногда вам может пригодиться [кеширование|caching:], например, если вы скачиваете и отображаете фиды.
В наше время, когда скорость и эффективность являются ключевыми, важно иметь инструменты, которые позволят вам достигать результатов без лишних задержек. Фреймворк Nette предлагает именно это - быструю разработку, безопасность и широкий спектр инструментов, таких как Tracy и Latte, которые упрощают процесс. Достаточно установить несколько пакетов Nette, и создание такого микросайта становится совершенно простым делом. И вы знаете, что нигде не скрывается никакой дыры в безопасности.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/pagination.texy b/best-practices/ru/pagination.texy
index 99d59c4272..15756e6d22 100644
--- a/best-practices/ru/pagination.texy
+++ b/best-practices/ru/pagination.texy
@@ -271,4 +271,3 @@ class HomePresenter extends Nette\Application\UI\Presenter
Таким образом, мы реализовали механизм пагинации без использования Paginator.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/passing-settings-to-presenters.texy b/best-practices/ru/passing-settings-to-presenters.texy
index c4d0f44be3..b65b1186c6 100644
--- a/best-practices/ru/passing-settings-to-presenters.texy
+++ b/best-practices/ru/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/post-links.texy b/best-practices/ru/post-links.texy
index 1783d13aed..59daf4a9e5 100644
--- a/best-practices/ru/post-links.texy
+++ b/best-practices/ru/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Этот подход не только улучшает безопасность вашего приложения, но и способствует соблюдению правильных веб-стандартов и практик. Используя методы POST для действий, изменяющих состояние, вы достигнете более надежного и безопасного приложения.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/presenter-traits.texy b/best-practices/ru/presenter-traits.texy
index 00d90c6d73..96d90aef15 100644
--- a/best-practices/ru/presenter-traits.texy
+++ b/best-practices/ru/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/ru/restore-request.texy b/best-practices/ru/restore-request.texy
index ce9771090b..19f5c12df1 100644
--- a/best-practices/ru/restore-request.texy
+++ b/best-practices/ru/restore-request.texy
@@ -60,4 +60,3 @@ class SignPresenter extends Nette\Application\UI\Presenter
Однако, если ключ недействителен (например, его уже нет в сессии), метод ничего не делает. Затем следует вызов `$this->redirect('Admin:')`, который перенаправляет на `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/@home.texy b/best-practices/sl/@home.texy
index 76a34361e5..a4cf0efbec 100644
--- a/best-practices/sl/@home.texy
+++ b/best-practices/sl/@home.texy
@@ -67,6 +67,3 @@ Stotine posnetkov iz Poslednjih sobot in videov o Nette najdete pod eno streho n
-
-{{sitename: Best Practices}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/sl/@meta.texy b/best-practices/sl/@meta.texy
new file mode 100644
index 0000000000..f58ad17850
--- /dev/null
+++ b/best-practices/sl/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Navodila in postopki}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/sl/attribute-requires.texy b/best-practices/sl/attribute-requires.texy
index 1f3334ed4b..8fb0588c40 100644
--- a/best-practices/sl/attribute-requires.texy
+++ b/best-practices/sl/attribute-requires.texy
@@ -175,5 +175,3 @@ Zaključek
---------
Atribut `#[Requires]` vam daje veliko fleksibilnosti in nadzora nad tem, kako so vaše spletne strani dostopne. S pomočjo preprostih, a močnih pravil lahko povečate varnost in pravilno delovanje vaše aplikacije. Kot vidite, lahko uporaba atributov v Nette vaše delo ne samo olajša, ampak tudi zavaruje.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/composer.texy b/best-practices/sl/composer.texy
index 177d01f103..bcfe1802c9 100644
--- a/best-practices/sl/composer.texy
+++ b/best-practices/sl/composer.texy
@@ -280,5 +280,3 @@ Composer je tesno povezan z orodjem za verzioniranje [Git |https://git-scm.com].
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/creating-editing-form.texy b/best-practices/sl/creating-editing-form.texy
index 6d3837b4d3..650812cb3a 100644
--- a/best-practices/sl/creating-editing-form.texy
+++ b/best-practices/sl/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/dynamic-snippets.texy b/best-practices/sl/dynamic-snippets.texy
index c6e6258a1d..1f5704cd9c 100644
--- a/best-practices/sl/dynamic-snippets.texy
+++ b/best-practices/sl/dynamic-snippets.texy
@@ -171,4 +171,3 @@ Predloga pogleda (view) se zmanjša na nujni minimum (in je popolnoma brez snipp
Skoraj smo končali: aplikacija bo zdaj delovala AJAX-ovsko. Tudi tukaj nas čaka optimizacija aplikacije, saj se zaradi uporabe Nette Database pri obdelavi signala nepotrebno naložijo vsi članki iz podatkovne baze namesto enega. Prednost pa je, da ne pride do njihovega izrisovanja, ker se dejansko izriše samo naša komponenta.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/editors-and-tools.texy b/best-practices/sl/editors-and-tools.texy
index e9473cb593..9ac5d2ff3c 100644
--- a/best-practices/sl/editors-and-tools.texy
+++ b/best-practices/sl/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
To je bilo orodje, ki je testiralo izvajalno okolje strežnika in obveščalo, ali (in v kolikšni meri) je mogoče ogrodje uporabljati. Trenutno je Nette mogoče uporabljati na vsakem strežniku, ki ima minimalno zahtevano različico PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/form-reuse.texy b/best-practices/sl/form-reuse.texy
index fb33c64c4f..4a388acd07 100644
--- a/best-practices/sl/form-reuse.texy
+++ b/best-practices/sl/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/inject-method-attribute.texy b/best-practices/sl/inject-method-attribute.texy
index 6b501ca408..e09c5e2471 100644
--- a/best-practices/sl/inject-method-attribute.texy
+++ b/best-practices/sl/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Prednost tega načina posredovanja odvisnosti je bila zelo varčna oblika zapisa. Vendar pa se z uvedbo [constructor property promotion |https://blog.nette.org/sl/php-8-0-complete-overview-of-news#toc-constructor-property-promotion] zdi lažje uporabiti konstruktor.
Nasprotno pa ta način trpi za enakimi pomanjkljivostmi kot posredovanje odvisnosti v lastnosti (properties) na splošno: nimamo nadzora nad spremembami v spremenljivki in hkrati spremenljivka postane del javnega vmesnika razreda, kar je nezaželeno.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/lets-create-contact-form.texy b/best-practices/sl/lets-create-contact-form.texy
index 9f5c5874e6..ed3d4baf0b 100644
--- a/best-practices/sl/lets-create-contact-form.texy
+++ b/best-practices/sl/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
In končano!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/microsites.texy b/best-practices/sl/microsites.texy
index c73853d1d2..fd4a5be3f2 100644
--- a/best-practices/sl/microsites.texy
+++ b/best-practices/sl/microsites.texy
@@ -61,5 +61,3 @@ Zakaj uporabljati Nette za mikro-spletna mesta?
- Včasih vam lahko koristi [predpomnjenje|caching:], na primer če prenašate in prikazujete vire (feeds).
V današnjem času, ko sta hitrost in učinkovitost ključnega pomena, je pomembno imeti orodja, ki vam omogočajo doseganje rezultatov brez nepotrebnega odlašanja. Ogrodje Nette vam ponuja prav to - hiter razvoj, varnost in široko paleto orodij, kot sta Tracy in Latte, ki poenostavljajo proces. Dovolj je namestiti nekaj Nette paketov in zgraditi takšno mikro-spletno mesto je naenkrat povsem enostavno. In veste, da se nikjer ne skriva nobena varnostna luknja.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/pagination.texy b/best-practices/sl/pagination.texy
index 8047731a85..f543008252 100644
--- a/best-practices/sl/pagination.texy
+++ b/best-practices/sl/pagination.texy
@@ -271,4 +271,3 @@ Ker v predlogo zdaj ne pošiljamo Paginatorja, prilagodimo del, ki prikazuje pov
Na ta način smo implementirali mehanizem za stranskanje brez uporabe Paginatorja.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/passing-settings-to-presenters.texy b/best-practices/sl/passing-settings-to-presenters.texy
index 4a4e6a67b4..8ced4b88f2 100644
--- a/best-practices/sl/passing-settings-to-presenters.texy
+++ b/best-practices/sl/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/post-links.texy b/best-practices/sl/post-links.texy
index 752b22733a..0b99158d78 100644
--- a/best-practices/sl/post-links.texy
+++ b/best-practices/sl/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Ta pristop ne samo izboljšuje varnost vaše aplikacije, ampak tudi prispeva k spoštovanju pravilnih spletnih standardov in praks. Z uporabo metod POST za akcije, ki spreminjajo stanje, dosežete bolj robustno in varnejšo aplikacijo.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/presenter-traits.texy b/best-practices/sl/presenter-traits.texy
index b07e18f8de..894c0add0e 100644
--- a/best-practices/sl/presenter-traits.texy
+++ b/best-practices/sl/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/sl/restore-request.texy b/best-practices/sl/restore-request.texy
index 80bdec2010..6f81a2d371 100644
--- a/best-practices/sl/restore-request.texy
+++ b/best-practices/sl/restore-request.texy
@@ -60,4 +60,3 @@ Metodi `restoreRequest()` posredujemo ključ shranjene zahteve in ta preusmeri (
Če pa je ključ neveljaven (na primer že ne obstaja v seji), metoda ne naredi ničesar. Sledi torej klic `$this->redirect('Admin:')`, ki preusmeri na `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/@home.texy b/best-practices/tr/@home.texy
index 6a83e8a3f6..c8b90b9e40 100644
--- a/best-practices/tr/@home.texy
+++ b/best-practices/tr/@home.texy
@@ -67,6 +67,3 @@ Poslední soboty'den yüzlerce kayıt ve Nette hakkındaki videoları tek bir ç
-
-{{sitename: En İyi Uygulamalar}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/tr/@meta.texy b/best-practices/tr/@meta.texy
new file mode 100644
index 0000000000..7f915d9a01
--- /dev/null
+++ b/best-practices/tr/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Kılavuzlar ve yöntemler}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/tr/attribute-requires.texy b/best-practices/tr/attribute-requires.texy
index e73ab1f47f..0fe1f082f5 100644
--- a/best-practices/tr/attribute-requires.texy
+++ b/best-practices/tr/attribute-requires.texy
@@ -175,5 +175,3 @@ Sonuç
-----
`#[Requires]` niteliği, web sayfalarınızın nasıl erişilebilir olduğu konusunda size büyük esneklik ve kontrol sağlar. Basit ama güçlü kurallar kullanarak uygulamanızın güvenliğini ve doğru çalışmasını artırabilirsiniz. Gördüğünüz gibi, Nette'de nitelikleri kullanmak işinizi yalnızca kolaylaştırmakla kalmaz, aynı zamanda güvence altına da alabilir.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/composer.texy b/best-practices/tr/composer.texy
index ca8dc89f6d..c0eb5fb788 100644
--- a/best-practices/tr/composer.texy
+++ b/best-practices/tr/composer.texy
@@ -280,5 +280,3 @@ Composer, [Git |https://git-scm.com] sürüm kontrol aracıyla yakından bağlan
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/creating-editing-form.texy b/best-practices/tr/creating-editing-form.texy
index 2bd0873f58..0274a0e122 100644
--- a/best-practices/tr/creating-editing-form.texy
+++ b/best-practices/tr/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/dynamic-snippets.texy b/best-practices/tr/dynamic-snippets.texy
index fd04e468c3..c805aeedb5 100644
--- a/best-practices/tr/dynamic-snippets.texy
+++ b/best-practices/tr/dynamic-snippets.texy
@@ -171,4 +171,3 @@ Görünüm şablonu gerekli minimuma indirildi (ve tamamen snippet'lerden arınd
Neredeyse bitti: uygulama artık AJAX ile çalışacak. Burada da uygulamayı optimize etmemiz gerekiyor, çünkü Nette Database kullanımı nedeniyle, sinyal işlenirken veritabanından tüm makaleler gereksiz yere yüklenir, oysa sadece bir tanesi yeterlidir. Ancak avantajı, bunların oluşturulmamasıdır, çünkü gerçekten sadece bizim bileşenimiz oluşturulur.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/editors-and-tools.texy b/best-practices/tr/editors-and-tools.texy
index d4c17be900..e1822a4311 100644
--- a/best-practices/tr/editors-and-tools.texy
+++ b/best-practices/tr/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Sunucunun çalışma zamanı ortamını test eden ve framework'ün kullanılıp kullanılamayacağını (ve ne ölçüde) bildiren bir araçtı. Şu anda Nette, minimum gerekli PHP sürümüne sahip her sunucuda kullanılabilir.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/form-reuse.texy b/best-practices/tr/form-reuse.texy
index e9c842e565..224e9f00d7 100644
--- a/best-practices/tr/form-reuse.texy
+++ b/best-practices/tr/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/inject-method-attribute.texy b/best-practices/tr/inject-method-attribute.texy
index cdf5ca75bb..95d08e2e06 100644
--- a/best-practices/tr/inject-method-attribute.texy
+++ b/best-practices/tr/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Bu bağımlılık iletme yönteminin avantajı, çok kısa bir yazım şekli olmasıydı. Ancak, [constructor property promotion |https://blog.nette.org/tr/php-8-0-complete-overview-of-news#toc-constructor-property-promotion] 'ın gelişiyle, yapıcıyı kullanmak daha kolay görünüyor.
Tersine, bu yöntem, genel olarak özelliklere bağımlılık iletmeyle aynı dezavantajlara sahiptir: değişken üzerindeki değişiklikler üzerinde kontrolümüz yoktur ve aynı zamanda değişken, sınıfın genel arayüzünün bir parçası haline gelir, ki bu istenmeyen bir durumdur.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/lets-create-contact-form.texy b/best-practices/tr/lets-create-contact-form.texy
index b16c31a93f..042f486703 100644
--- a/best-practices/tr/lets-create-contact-form.texy
+++ b/best-practices/tr/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
Ve işimiz bitti!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/microsites.texy b/best-practices/tr/microsites.texy
index daaf4087cf..fca2a1ebeb 100644
--- a/best-practices/tr/microsites.texy
+++ b/best-practices/tr/microsites.texy
@@ -61,5 +61,3 @@ Neden mikro siteler için Nette kullanmalı?
- Bazen [önbelleğe alma|caching:] işinize yarayabilir, örneğin beslemeleri indirip görüntülüyorsanız.
Hız ve verimliliğin anahtar olduğu günümüzde, gereksiz gecikmeler olmadan sonuçlara ulaşmanızı sağlayan araçlara sahip olmak önemlidir. Nette framework size tam da bunu sunar - hızlı geliştirme, güvenlik ve süreci basitleştiren Tracy ve Latte gibi geniş bir araç yelpazesi. Sadece birkaç Nette paketi yükleyin ve böyle bir mikro site oluşturmak birdenbire çocuk oyuncağı haline gelir. Ve hiçbir yerde gizli bir güvenlik açığı olmadığını bilirsiniz.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/pagination.texy b/best-practices/tr/pagination.texy
index 913c5dfe47..92509706a7 100644
--- a/best-practices/tr/pagination.texy
+++ b/best-practices/tr/pagination.texy
@@ -271,4 +271,3 @@ class HomePresenter extends Nette\Application\UI\Presenter
Bu şekilde, Paginator kullanmadan sayfalama mekanizmasını uyguladık.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/passing-settings-to-presenters.texy b/best-practices/tr/passing-settings-to-presenters.texy
index 454f5157aa..b71ddc741d 100644
--- a/best-practices/tr/passing-settings-to-presenters.texy
+++ b/best-practices/tr/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/post-links.texy b/best-practices/tr/post-links.texy
index 7c22376f68..4d4ca45666 100644
--- a/best-practices/tr/post-links.texy
+++ b/best-practices/tr/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Bu yaklaşım yalnızca uygulamanızın güvenliğini artırmakla kalmaz, aynı zamanda doğru web standartlarına ve uygulamalarına uymaya da katkıda bulunur. Durumu değiştiren eylemler için POST yöntemlerini kullanarak daha sağlam ve güvenli bir uygulama elde edersiniz.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/presenter-traits.texy b/best-practices/tr/presenter-traits.texy
index 40751aea03..a75c15f500 100644
--- a/best-practices/tr/presenter-traits.texy
+++ b/best-practices/tr/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/tr/restore-request.texy b/best-practices/tr/restore-request.texy
index 3ad6156f6b..0316b1cc68 100644
--- a/best-practices/tr/restore-request.texy
+++ b/best-practices/tr/restore-request.texy
@@ -60,4 +60,3 @@ class SignPresenter extends Nette\Application\UI\Presenter
Ancak anahtar geçersizse (örneğin, artık oturumda mevcut değilse), metot hiçbir şey yapmaz. Bu nedenle, `AdminPresenter`'a yönlendiren `$this->redirect('Admin:')` çağrısı takip eder.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/@home.texy b/best-practices/uk/@home.texy
index 7ea5601bb5..f9d3510c2b 100644
--- a/best-practices/uk/@home.texy
+++ b/best-practices/uk/@home.texy
@@ -67,6 +67,3 @@
-
-{{sitename: Найкращі практики}}
-{{leftbar: www:@menu-common}}
diff --git a/best-practices/uk/@meta.texy b/best-practices/uk/@meta.texy
new file mode 100644
index 0000000000..5ad8bb9a6b
--- /dev/null
+++ b/best-practices/uk/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Посібники та практики}}
+{{leftbar: www:@menu-common}}
diff --git a/best-practices/uk/attribute-requires.texy b/best-practices/uk/attribute-requires.texy
index ed222211dd..f0d8d4a2d1 100644
--- a/best-practices/uk/attribute-requires.texy
+++ b/best-practices/uk/attribute-requires.texy
@@ -175,5 +175,3 @@ class ApiPresenter extends Nette\Application\UI\Presenter
--------
Атрибут `#[Requires]` надає вам велику гнучкість і контроль над тим, як доступні ваші веб-сторінки. За допомогою простих, але потужних правил ви можете підвищити безпеку та правильне функціонування вашого додатку. Як бачите, використання атрибутів у Nette може не тільки полегшити вашу роботу, але й зробити її безпечнішою.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/composer.texy b/best-practices/uk/composer.texy
index b49e376877..a237caf401 100644
--- a/best-practices/uk/composer.texy
+++ b/best-practices/uk/composer.texy
@@ -280,5 +280,3 @@ Composer тісно пов'язаний з інструментом версіо
```shell
composer -g config preferred-install dist
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/creating-editing-form.texy b/best-practices/uk/creating-editing-form.texy
index 813666b04c..415142d3ae 100644
--- a/best-practices/uk/creating-editing-form.texy
+++ b/best-practices/uk/creating-editing-form.texy
@@ -203,4 +203,3 @@ class RecordPresenter extends Nette\Application\UI\Presenter
```
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/dynamic-snippets.texy b/best-practices/uk/dynamic-snippets.texy
index 790cfe06a9..3a8f9f5f63 100644
--- a/best-practices/uk/dynamic-snippets.texy
+++ b/best-practices/uk/dynamic-snippets.texy
@@ -171,4 +171,3 @@ protected function createComponentLikeControl()
Майже готово: додаток тепер працюватиме за допомогою AJAX. Тут також нас чекає оптимізація додатку, оскільки через використання Nette Database при обробці сигналу марно завантажуються всі статті з бази даних замість однієї. Перевагою, однак, є те, що їх рендеринг не відбудеться, оскільки відрендериться дійсно лише наш компонент.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/editors-and-tools.texy b/best-practices/uk/editors-and-tools.texy
index 87fc1d8218..86380ff279 100644
--- a/best-practices/uk/editors-and-tools.texy
+++ b/best-practices/uk/editors-and-tools.texy
@@ -82,5 +82,3 @@ Requirements Checker
====================
Це був інструмент, який тестував середовище виконання сервера та інформував, чи (і якою мірою) можна використовувати фреймворк. На даний момент Nette можна використовувати на будь-якому сервері, який має мінімально необхідну версію PHP.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/form-reuse.texy b/best-practices/uk/form-reuse.texy
index b007c85afa..d75d20642b 100644
--- a/best-practices/uk/form-reuse.texy
+++ b/best-practices/uk/form-reuse.texy
@@ -346,5 +346,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/inject-method-attribute.texy b/best-practices/uk/inject-method-attribute.texy
index 5496ce823f..8e64ef27ab 100644
--- a/best-practices/uk/inject-method-attribute.texy
+++ b/best-practices/uk/inject-method-attribute.texy
@@ -59,6 +59,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
Перевагою цього способу передачі залежностей була дуже лаконічна форма запису. Однак з появою [constructor property promotion |https://blog.nette.org/uk/php-8-0-complete-overview-of-news#toc-constructor-property-promotion] простіше використовувати конструктор.
Навпаки, цей спосіб страждає тими ж недоліками, що й передача залежності у властивості загалом: ми не маємо контролю над змінами в змінній, і водночас змінна стає частиною публічного інтерфейсу класу, що є небажаним.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/lets-create-contact-form.texy b/best-practices/uk/lets-create-contact-form.texy
index 7cdc5bf2ff..dda0437ab6 100644
--- a/best-practices/uk/lets-create-contact-form.texy
+++ b/best-practices/uk/lets-create-contact-form.texy
@@ -219,6 +219,3 @@ parameters:
```
І готово!
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/microsites.texy b/best-practices/uk/microsites.texy
index 40c404ed7d..19744c4b86 100644
--- a/best-practices/uk/microsites.texy
+++ b/best-practices/uk/microsites.texy
@@ -61,5 +61,3 @@ PHP-код в `index.php` спочатку [підготує середовищ
- Іноді вам може знадобитися [кешування|caching:], наприклад, якщо ви завантажуєте та відображаєте стрічки новин.
У наш час, коли швидкість та ефективність є ключовими, важливо мати інструменти, які дозволять вам досягти результатів без зайвих затримок. Фреймворк Nette пропонує саме це - швидку розробку, безпеку та широкий спектр інструментів, таких як Tracy та Latte, які спрощують процес. Достатньо встановити кілька пакетів Nette, і створення такого мікросайту раптом стає зовсім простою справою. І ви знаєте, що ніде не ховається жодна дірка в безпеці.
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/pagination.texy b/best-practices/uk/pagination.texy
index e34ae7f166..e16f7e4ad4 100644
--- a/best-practices/uk/pagination.texy
+++ b/best-practices/uk/pagination.texy
@@ -271,4 +271,3 @@ class HomePresenter extends Nette\Application\UI\Presenter
Таким чином ми реалізували механізм пагінації без використання Paginator.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/passing-settings-to-presenters.texy b/best-practices/uk/passing-settings-to-presenters.texy
index 4f3488c8cb..eab473dbda 100644
--- a/best-practices/uk/passing-settings-to-presenters.texy
+++ b/best-practices/uk/passing-settings-to-presenters.texy
@@ -47,5 +47,3 @@ class MyPresenter extends Nette\Application\UI\Presenter
}
}
```
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/post-links.texy b/best-practices/uk/post-links.texy
index 63e68b4a8c..d0c67a0506 100644
--- a/best-practices/uk/post-links.texy
+++ b/best-practices/uk/post-links.texy
@@ -54,6 +54,3 @@ public function handleDelete(int $id): void
```
Цей підхід не тільки покращує безпеку вашого додатку, але й сприяє дотриманню правильних веб-стандартів та практик. Використовуючи методи POST для дій, що змінюють стан, ви досягнете більш надійного та безпечного додатку.
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/presenter-traits.texy b/best-practices/uk/presenter-traits.texy
index c83bcb32f6..3b4ce8a1cb 100644
--- a/best-practices/uk/presenter-traits.texy
+++ b/best-practices/uk/presenter-traits.texy
@@ -45,6 +45,3 @@ class ArticlePresenter extends Nette\Application\UI\Presenter
use RequireLoggedUser;
}
```
-
-
-{{sitename: Best Practices}}
diff --git a/best-practices/uk/restore-request.texy b/best-practices/uk/restore-request.texy
index 4bef72edcf..63446e2b95 100644
--- a/best-practices/uk/restore-request.texy
+++ b/best-practices/uk/restore-request.texy
@@ -60,4 +60,3 @@ class SignPresenter extends Nette\Application\UI\Presenter
Однак, якщо ключ недійсний (наприклад, вже не існує в сесії), метод нічого не робить. Тому далі йде виклик `$this->redirect('Admin:')`, який перенаправляє на `AdminPresenter`.
{{priority: -1}}
-{{sitename: Best Practices}}
diff --git a/bootstrap/bg/@home.texy b/bootstrap/bg/@home.texy
index 7949a81530..3f9b20f4a1 100644
--- a/bootstrap/bg/@home.texy
+++ b/bootstrap/bg/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Параметърът `projectId` може да бъде рефериран в конфигурацията чрез запис `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/bg/@meta.texy b/bootstrap/bg/@meta.texy
new file mode 100644
index 0000000000..794cbc8522
--- /dev/null
+++ b/bootstrap/bg/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документация на Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/cs/@home.texy b/bootstrap/cs/@home.texy
index d1f5e0bdb2..9e3f2acaa6 100644
--- a/bootstrap/cs/@home.texy
+++ b/bootstrap/cs/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Na parametr `projectId` se lze v konfiguraci odkázat zápisem `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/cs/@meta.texy b/bootstrap/cs/@meta.texy
new file mode 100644
index 0000000000..08edde785b
--- /dev/null
+++ b/bootstrap/cs/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentace}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/de/@home.texy b/bootstrap/de/@home.texy
index 316e9f7db6..8f49650c62 100644
--- a/bootstrap/de/@home.texy
+++ b/bootstrap/de/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Auf den Parameter `projectId` kann in der Konfiguration mit der Notation `%projectId%` verwiesen werden.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/de/@meta.texy b/bootstrap/de/@meta.texy
new file mode 100644
index 0000000000..2cf383a5cf
--- /dev/null
+++ b/bootstrap/de/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentation}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/el/@home.texy b/bootstrap/el/@home.texy
index 01358f0f79..8b4cf46446 100644
--- a/bootstrap/el/@home.texy
+++ b/bootstrap/el/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Στην παράμετρο `projectId` μπορεί να γίνει αναφορά στη διαμόρφωση με τη σύνταξη `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/el/@meta.texy b/bootstrap/el/@meta.texy
new file mode 100644
index 0000000000..a09ce5fe0d
--- /dev/null
+++ b/bootstrap/el/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Τεκμηρίωση}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/en/@home.texy b/bootstrap/en/@home.texy
index ba40d2c3f2..202b427f3e 100644
--- a/bootstrap/en/@home.texy
+++ b/bootstrap/en/@home.texy
@@ -93,7 +93,4 @@ $configurator->addDynamicParameters([
]);
```
-The `projectId` parameter can be referenced in the configuration using the `%projectId%` notation.
-
-
-{{leftbar: nette:@menu-topics}}
+The `remoteIp` parameter can be referenced in the configuration using the `%remoteIp%` notation.
diff --git a/bootstrap/en/@meta.texy b/bootstrap/en/@meta.texy
new file mode 100644
index 0000000000..91205786e5
--- /dev/null
+++ b/bootstrap/en/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Documentation}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/es/@home.texy b/bootstrap/es/@home.texy
index 3e2a2af551..25321bada6 100644
--- a/bootstrap/es/@home.texy
+++ b/bootstrap/es/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Se puede hacer referencia al parámetro `projectId` en la configuración usando la notación `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/es/@meta.texy b/bootstrap/es/@meta.texy
new file mode 100644
index 0000000000..25d506cde9
--- /dev/null
+++ b/bootstrap/es/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Documentación}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/fr/@home.texy b/bootstrap/fr/@home.texy
index d103bfecab..25f662ac6c 100644
--- a/bootstrap/fr/@home.texy
+++ b/bootstrap/fr/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Le paramètre `projectId` peut être référencé dans la configuration en utilisant la notation `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/fr/@meta.texy b/bootstrap/fr/@meta.texy
new file mode 100644
index 0000000000..95ec8a4ef6
--- /dev/null
+++ b/bootstrap/fr/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentation Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/hu/@home.texy b/bootstrap/hu/@home.texy
index 5f678c7862..86a0ca10df 100644
--- a/bootstrap/hu/@home.texy
+++ b/bootstrap/hu/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
A `projectId` paraméterre a konfigurációban a `%projectId%` jelöléssel hivatkozhatunk.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/hu/@meta.texy b/bootstrap/hu/@meta.texy
new file mode 100644
index 0000000000..c00a2158aa
--- /dev/null
+++ b/bootstrap/hu/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette dokumentáció}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/it/@home.texy b/bootstrap/it/@home.texy
index 010aa00503..72a8b4d1f0 100644
--- a/bootstrap/it/@home.texy
+++ b/bootstrap/it/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Al parametro `projectId` si può fare riferimento nella configurazione tramite la notazione `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/it/@meta.texy b/bootstrap/it/@meta.texy
new file mode 100644
index 0000000000..9d19e7312c
--- /dev/null
+++ b/bootstrap/it/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentazione Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/ja/@home.texy b/bootstrap/ja/@home.texy
index 3643ae7ed2..80ea76d567 100644
--- a/bootstrap/ja/@home.texy
+++ b/bootstrap/ja/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
パラメータ `projectId` は、設定内で `%projectId%` と記述することで参照できます。
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/ja/@meta.texy b/bootstrap/ja/@meta.texy
new file mode 100644
index 0000000000..7d67dcb7b8
--- /dev/null
+++ b/bootstrap/ja/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette ドキュメンテーション}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/pl/@home.texy b/bootstrap/pl/@home.texy
index 4fb23f2d46..5089994f3b 100644
--- a/bootstrap/pl/@home.texy
+++ b/bootstrap/pl/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Do parametru `projectId` można się odwołać w konfiguracji zapisem `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/pl/@meta.texy b/bootstrap/pl/@meta.texy
new file mode 100644
index 0000000000..08f2227fb5
--- /dev/null
+++ b/bootstrap/pl/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Dokumentacja Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/pt/@home.texy b/bootstrap/pt/@home.texy
index 5ae38a0ce4..0344fc188a 100644
--- a/bootstrap/pt/@home.texy
+++ b/bootstrap/pt/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
O parâmetro `projectId` pode ser referenciado na configuração usando a notação `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/pt/@meta.texy b/bootstrap/pt/@meta.texy
new file mode 100644
index 0000000000..e2566bcb44
--- /dev/null
+++ b/bootstrap/pt/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentação Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/ro/@home.texy b/bootstrap/ro/@home.texy
index e1b4c07cf6..16606ee9e5 100644
--- a/bootstrap/ro/@home.texy
+++ b/bootstrap/ro/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Parametrul `projectId` poate fi referențiat în configurație prin notația `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/ro/@meta.texy b/bootstrap/ro/@meta.texy
new file mode 100644
index 0000000000..6554692600
--- /dev/null
+++ b/bootstrap/ro/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentație Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/ru/@home.texy b/bootstrap/ru/@home.texy
index 8b69c4f8de..ec99937fd8 100644
--- a/bootstrap/ru/@home.texy
+++ b/bootstrap/ru/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
На параметр `projectId` можно ссылаться в конфигурации с помощью записи `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/ru/@meta.texy b/bootstrap/ru/@meta.texy
new file mode 100644
index 0000000000..61577d6323
--- /dev/null
+++ b/bootstrap/ru/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документация Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/sl/@home.texy b/bootstrap/sl/@home.texy
index b7d6c3c107..76641a1cce 100644
--- a/bootstrap/sl/@home.texy
+++ b/bootstrap/sl/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
Na parameter `projectId` se lahko v konfiguraciji sklicujete z zapisom `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/sl/@meta.texy b/bootstrap/sl/@meta.texy
new file mode 100644
index 0000000000..282883a3d6
--- /dev/null
+++ b/bootstrap/sl/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentacija}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/tr/@home.texy b/bootstrap/tr/@home.texy
index ce17d0d8a1..732122fed8 100644
--- a/bootstrap/tr/@home.texy
+++ b/bootstrap/tr/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
`projectId` parametresine yapılandırmada `%projectId%` yazılarak başvurulabilir.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/tr/@meta.texy b/bootstrap/tr/@meta.texy
new file mode 100644
index 0000000000..e5c5cea355
--- /dev/null
+++ b/bootstrap/tr/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokümantasyonu}}
+{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/uk/@home.texy b/bootstrap/uk/@home.texy
index e62aa8fff2..1320bdf9fa 100644
--- a/bootstrap/uk/@home.texy
+++ b/bootstrap/uk/@home.texy
@@ -94,6 +94,3 @@ $configurator->addDynamicParameters([
```
На параметр `projectId` можна посилатися в конфігурації записом `%projectId%`.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/bootstrap/uk/@meta.texy b/bootstrap/uk/@meta.texy
new file mode 100644
index 0000000000..083a8ab9f7
--- /dev/null
+++ b/bootstrap/uk/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документація Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/bg/@home.texy b/caching/bg/@home.texy
index 47c8c206a5..8c04a7e659 100644
--- a/caching/bg/@home.texy
+++ b/caching/bg/@home.texy
@@ -482,6 +482,3 @@ services:
```
Тази настройка не влияе на кеширането на шаблони в Latte или DI контейнера, тъй като тези библиотеки не използват услугите на nette/caching и управляват кеша си самостоятелно. Техният кеш впрочем [не е необходимо да се изключва |nette:troubleshooting#Как да изключите кеша по време на разработка] в режим на разработка.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/bg/@meta.texy b/caching/bg/@meta.texy
new file mode 100644
index 0000000000..794cbc8522
--- /dev/null
+++ b/caching/bg/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документация на Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/cs/@home.texy b/caching/cs/@home.texy
index 01638b4496..1d3f3eed17 100644
--- a/caching/cs/@home.texy
+++ b/caching/cs/@home.texy
@@ -125,7 +125,7 @@ Nebo pomocí 3. parametru v metodě `load()`, např:
```php
$value = $cache->load($key, function () {
- return ...;
+ return /* ... */;
}, [Cache::Expire => '20 minutes']);
```
@@ -293,7 +293,7 @@ Velmi elegantně lze zachytávat a cachovat výstup:
```php
if ($capture = $cache->capture($key)) {
- echo ... // vypisujeme data
+ // echo ... vypisujeme data
$capture->end(); // uložíme výstup do cache
}
@@ -482,6 +482,3 @@ services:
```
Toto nastavení nemá vliv na kešování šablon v Latte nebo DI kontejeru, protože tyto knihovny nevyužívají služeb nette/caching a spravují si cache samostatně. Jejich cache ostatně [není potřeba |nette:troubleshooting#Jak vypnout cache během vývoje] ve vývojářském režimu vypínat.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/cs/@meta.texy b/caching/cs/@meta.texy
new file mode 100644
index 0000000000..08edde785b
--- /dev/null
+++ b/caching/cs/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentace}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/de/@home.texy b/caching/de/@home.texy
index 07292cfb61..d2c2c5186a 100644
--- a/caching/de/@home.texy
+++ b/caching/de/@home.texy
@@ -482,6 +482,3 @@ services:
```
Diese Einstellung hat keinen Einfluss auf das Caching von Templates in Latte oder des DI-Containers, da diese Bibliotheken die Dienste von `nette/caching` nicht nutzen und ihren Cache selbst verwalten. Ihr Cache muss im Entwicklermodus übrigens [nicht deaktiviert werden |nette:troubleshooting#Wie schaltet man den Cache während der Entwicklung aus].
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/de/@meta.texy b/caching/de/@meta.texy
new file mode 100644
index 0000000000..2cf383a5cf
--- /dev/null
+++ b/caching/de/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentation}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/el/@home.texy b/caching/el/@home.texy
index 2471374f2c..a9c9f774d5 100644
--- a/caching/el/@home.texy
+++ b/caching/el/@home.texy
@@ -482,6 +482,3 @@ services:
```
Αυτή η ρύθμιση δεν επηρεάζει το caching των προτύπων στο Latte ή τον DI container, καθώς αυτές οι βιβλιοθήκες δεν χρησιμοποιούν τις υπηρεσίες nette/caching και διαχειρίζονται την cache τους ανεξάρτητα. Εξάλλου, η cache τους [δεν χρειάζεται να απενεργοποιηθεί |nette:troubleshooting#Πώς να απενεργοποιήσετε την cache κατά την ανάπτυξη] στη λειτουργία ανάπτυξης.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/el/@meta.texy b/caching/el/@meta.texy
new file mode 100644
index 0000000000..a09ce5fe0d
--- /dev/null
+++ b/caching/el/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Τεκμηρίωση}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/en/@home.texy b/caching/en/@home.texy
index 8f3f5c102e..e3557a0539 100644
--- a/caching/en/@home.texy
+++ b/caching/en/@home.texy
@@ -125,7 +125,7 @@ Or by using the 3rd parameter of the `load()` method itself, e.g.:
```php
$value = $cache->load($key, function () {
- return ...;
+ return /* ... */;
}, [Cache::Expire => '20 minutes']);
```
@@ -293,7 +293,7 @@ Output can be captured and cached very elegantly:
```php
if ($capture = $cache->capture($key)) {
- echo ... // printing some data
+ // echo ... printing some data
$capture->end(); // save the output to the cache
}
@@ -482,6 +482,3 @@ services:
```
This setting does not affect the caching of Latte templates or the DI container, as these libraries do not utilize `nette/caching` services and manage their caches independently. Furthermore, their caches [do not typically need to be disabled |nette:troubleshooting#How to Disable Cache During Development] during development mode.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/en/@meta.texy b/caching/en/@meta.texy
new file mode 100644
index 0000000000..91205786e5
--- /dev/null
+++ b/caching/en/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Documentation}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/es/@home.texy b/caching/es/@home.texy
index f319d5890b..ce53dca55f 100644
--- a/caching/es/@home.texy
+++ b/caching/es/@home.texy
@@ -482,6 +482,3 @@ services:
```
Esta configuración no afecta el almacenamiento en caché de plantillas en Latte o el contenedor DI, ya que estas librerías no utilizan los servicios de nette/caching y gestionan su caché de forma independiente. Además, su caché [no necesita ser desactivada |nette:troubleshooting#Cómo desactivar la caché durante el desarrollo] en el modo de desarrollo.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/es/@meta.texy b/caching/es/@meta.texy
new file mode 100644
index 0000000000..25d506cde9
--- /dev/null
+++ b/caching/es/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Documentación}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/fr/@home.texy b/caching/fr/@home.texy
index cc0f5d5e81..f0dabcdc54 100644
--- a/caching/fr/@home.texy
+++ b/caching/fr/@home.texy
@@ -482,6 +482,3 @@ services:
```
Ce paramètre n'affecte pas la mise en cache des templates dans Latte ou du conteneur DI, car ces bibliothèques n'utilisent pas les services nette/caching et gèrent leur propre cache indépendamment. D'ailleurs, leur cache [n'a pas besoin d'être désactivé |nette:troubleshooting#Comment désactiver le cache pendant le développement] en mode développeur.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/fr/@meta.texy b/caching/fr/@meta.texy
new file mode 100644
index 0000000000..95ec8a4ef6
--- /dev/null
+++ b/caching/fr/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentation Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/hu/@home.texy b/caching/hu/@home.texy
index f9f4a3d4b5..25518b3721 100644
--- a/caching/hu/@home.texy
+++ b/caching/hu/@home.texy
@@ -482,6 +482,3 @@ services:
```
Ez a beállítás nincs hatással a sablonok gyorsítótárazására a Latte-ban vagy a DI konténerben, mivel ezek a könyvtárak nem használják a nette/caching szolgáltatásait, és önállóan kezelik a cache-t. Egyébként a cache-üket [nem szükséges kikapcsolni |nette:troubleshooting#Hogyan kapcsoljuk ki a cache-t fejlesztés közben] fejlesztői módban.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/hu/@meta.texy b/caching/hu/@meta.texy
new file mode 100644
index 0000000000..c00a2158aa
--- /dev/null
+++ b/caching/hu/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette dokumentáció}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/it/@home.texy b/caching/it/@home.texy
index f09ff05ce4..3b9e0dba0b 100644
--- a/caching/it/@home.texy
+++ b/caching/it/@home.texy
@@ -482,6 +482,3 @@ services:
```
Questa impostazione non influisce sulla cache dei template in Latte o del container DI, poiché queste librerie non utilizzano i servizi di nette/caching e gestiscono la cache autonomamente. La loro cache, del resto, [non è necessario disattivare |nette:troubleshooting#Come disattivare la cache durante lo sviluppo] in modalità sviluppatore.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/it/@meta.texy b/caching/it/@meta.texy
new file mode 100644
index 0000000000..9d19e7312c
--- /dev/null
+++ b/caching/it/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentazione Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/ja/@home.texy b/caching/ja/@home.texy
index a7403892a4..50ae8d3d98 100644
--- a/caching/ja/@home.texy
+++ b/caching/ja/@home.texy
@@ -482,6 +482,3 @@ services:
```
この設定は、LatteのテンプレートやDIコンテナのキャッシュには影響しません。これらのライブラリはnette/cachingサービスを使用せず、独自のキャッシュを管理するためです。また、開発モードでは[これらのキャッシュを無効にする必要はありません |nette:troubleshooting#開発中にキャッシュを無効にする方法は]。
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/ja/@meta.texy b/caching/ja/@meta.texy
new file mode 100644
index 0000000000..7d67dcb7b8
--- /dev/null
+++ b/caching/ja/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette ドキュメンテーション}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/pl/@home.texy b/caching/pl/@home.texy
index d24055b70a..61fdbc3275 100644
--- a/caching/pl/@home.texy
+++ b/caching/pl/@home.texy
@@ -482,6 +482,3 @@ services:
```
To ustawienie nie ma wpływu na buforowanie szablonów w Latte ani kontenera DI, ponieważ te biblioteki nie korzystają z usług `nette/caching` i zarządzają swoją pamięcią podręczną samodzielnie. Ich cache zresztą [nie trzeba wyłączać |nette:troubleshooting#Jak wyłączyć cache podczas developmentu] w trybie deweloperskim.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/pl/@meta.texy b/caching/pl/@meta.texy
new file mode 100644
index 0000000000..08f2227fb5
--- /dev/null
+++ b/caching/pl/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Dokumentacja Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/pt/@home.texy b/caching/pt/@home.texy
index 09db0caa9f..82c8cbb29f 100644
--- a/caching/pt/@home.texy
+++ b/caching/pt/@home.texy
@@ -482,6 +482,3 @@ services:
```
Esta configuração não afeta o armazenamento em cache de templates no Latte ou no contêiner DI, pois essas bibliotecas não usam os serviços nette/caching e gerenciam sua própria cache de forma independente. Afinal, a cache delas [não precisa ser desativada |nette:troubleshooting#Como desativar o cache durante o desenvolvimento] no modo de desenvolvimento.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/pt/@meta.texy b/caching/pt/@meta.texy
new file mode 100644
index 0000000000..e2566bcb44
--- /dev/null
+++ b/caching/pt/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentação Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/ro/@home.texy b/caching/ro/@home.texy
index ec5ba3934d..2bff23a31e 100644
--- a/caching/ro/@home.texy
+++ b/caching/ro/@home.texy
@@ -482,6 +482,3 @@ services:
```
Această setare nu afectează stocarea în cache a șabloanelor în Latte sau a containerului DI, deoarece aceste biblioteci nu utilizează serviciile nette/caching și își gestionează cache-ul independent. Cache-ul lor, de altfel, [nu trebuie dezactivat |nette:troubleshooting#Cum să dezactivați cache-ul în timpul dezvoltării] în modul dezvoltator.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/ro/@meta.texy b/caching/ro/@meta.texy
new file mode 100644
index 0000000000..6554692600
--- /dev/null
+++ b/caching/ro/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentație Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/ru/@home.texy b/caching/ru/@home.texy
index ce84fe07e3..784e86d219 100644
--- a/caching/ru/@home.texy
+++ b/caching/ru/@home.texy
@@ -482,6 +482,3 @@ services:
```
Эта настройка не влияет на кеширование шаблонов в Latte или DI-контейнера, поскольку эти библиотеки не используют сервисы nette/caching и управляют своим кешем самостоятельно. Их кеш, впрочем, [нет необходимости |nette:troubleshooting#Как отключить кеш во время разработки] отключать в режиме разработки.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/ru/@meta.texy b/caching/ru/@meta.texy
new file mode 100644
index 0000000000..61577d6323
--- /dev/null
+++ b/caching/ru/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документация Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/sl/@home.texy b/caching/sl/@home.texy
index f7bb73edc5..f87e7a5f6e 100644
--- a/caching/sl/@home.texy
+++ b/caching/sl/@home.texy
@@ -482,6 +482,3 @@ services:
```
Ta nastavitev nima vpliva na predpomnjenje predlog v Latte ali DI vsebnika, ker te knjižnice ne uporabljajo storitev nette/caching in si upravljajo predpomnilnik samostojno. Njihovega predpomnilnika sicer [ni treba |nette:troubleshooting#Kako izklopiti predpomnilnik med razvojem] v razvojnem načinu izklapljati.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/sl/@meta.texy b/caching/sl/@meta.texy
new file mode 100644
index 0000000000..282883a3d6
--- /dev/null
+++ b/caching/sl/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentacija}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/tr/@home.texy b/caching/tr/@home.texy
index e4b0c8ea71..a14067b97e 100644
--- a/caching/tr/@home.texy
+++ b/caching/tr/@home.texy
@@ -482,6 +482,3 @@ services:
```
Bu ayarın Latte'deki şablonların veya DI konteynerinin önbelleğe alınması üzerinde bir etkisi yoktur, çünkü bu kütüphaneler nette/caching servislerini kullanmaz ve kendi önbelleklerini yönetirler. Ayrıca, geliştirme modunda [önbelleklerini devre dışı bırakmaya gerek yoktur |nette:troubleshooting#Geliştirme Sırasında Önbellek Nasıl Kapatılır].
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/tr/@meta.texy b/caching/tr/@meta.texy
new file mode 100644
index 0000000000..e5c5cea355
--- /dev/null
+++ b/caching/tr/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokümantasyonu}}
+{{leftbar: nette:@menu-topics}}
diff --git a/caching/uk/@home.texy b/caching/uk/@home.texy
index 6847d378ba..14e19a212f 100644
--- a/caching/uk/@home.texy
+++ b/caching/uk/@home.texy
@@ -482,6 +482,3 @@ services:
```
Це налаштування не впливає на кешування шаблонів у Latte або DI-контейнера, оскільки ці бібліотеки не використовують сервіси nette/caching і керують своїм кешем самостійно. Їхній кеш, до речі, [не потрібно |nette:troubleshooting#Як вимкнути кеш під час розробки] вимикати в режимі розробки.
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/caching/uk/@meta.texy b/caching/uk/@meta.texy
new file mode 100644
index 0000000000..083a8ab9f7
--- /dev/null
+++ b/caching/uk/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документація Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/bg/@home.texy b/component-model/bg/@home.texy
index f873252424..2209fed3e8 100644
--- a/component-model/bg/@home.texy
+++ b/component-model/bg/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
и щом формата е налична, се извиква callback. (Преди това вместо него се използваха общите методи `attached`, респ. `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/bg/@meta.texy b/component-model/bg/@meta.texy
new file mode 100644
index 0000000000..794cbc8522
--- /dev/null
+++ b/component-model/bg/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документация на Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/cs/@home.texy b/component-model/cs/@home.texy
index 1a80e31100..7aa17b402f 100644
--- a/component-model/cs/@home.texy
+++ b/component-model/cs/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
a jakmile je formulář k dispozici, zavolá se callback. (Dříve se místo něj používala společná metoda `attached` resp. `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/cs/@meta.texy b/component-model/cs/@meta.texy
new file mode 100644
index 0000000000..08edde785b
--- /dev/null
+++ b/component-model/cs/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentace}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/de/@home.texy b/component-model/de/@home.texy
index 20251ac43e..680880c8f3 100644
--- a/component-model/de/@home.texy
+++ b/component-model/de/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
und sobald das Formular verfügbar ist, wird der Callback aufgerufen. (Früher wurde stattdessen die gemeinsame Methode `attached` bzw. `detached` verwendet).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/de/@meta.texy b/component-model/de/@meta.texy
new file mode 100644
index 0000000000..2cf383a5cf
--- /dev/null
+++ b/component-model/de/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentation}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/el/@home.texy b/component-model/el/@home.texy
index ecf747d215..b38ccc1262 100644
--- a/component-model/el/@home.texy
+++ b/component-model/el/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
και μόλις η φόρμα είναι διαθέσιμη, καλείται το callback. (Παλαιότερα, χρησιμοποιούνταν αντί αυτού η κοινή μέθοδος `attached` ή `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/el/@meta.texy b/component-model/el/@meta.texy
new file mode 100644
index 0000000000..a09ce5fe0d
--- /dev/null
+++ b/component-model/el/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Τεκμηρίωση}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/en/@home.texy b/component-model/en/@home.texy
index ccfd4f05a4..ec18f76c32 100644
--- a/component-model/en/@home.texy
+++ b/component-model/en/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
and as soon as the form becomes available, the callback is invoked. (Previously, the common methods `attached` and `detached` were used for this purpose.)
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/en/@meta.texy b/component-model/en/@meta.texy
new file mode 100644
index 0000000000..91205786e5
--- /dev/null
+++ b/component-model/en/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Documentation}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/es/@home.texy b/component-model/es/@home.texy
index 1c272b7f46..515782fc79 100644
--- a/component-model/es/@home.texy
+++ b/component-model/es/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
y tan pronto como el formulario esté disponible, se llama al callback. (Anteriormente, se usaba el método común `attached` o `detached` en su lugar).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/es/@meta.texy b/component-model/es/@meta.texy
new file mode 100644
index 0000000000..25d506cde9
--- /dev/null
+++ b/component-model/es/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Documentación}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/fr/@home.texy b/component-model/fr/@home.texy
index fd91689007..706b8f46ce 100644
--- a/component-model/fr/@home.texy
+++ b/component-model/fr/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
et dès que le formulaire est disponible, le callback est appelé. (Auparavant, les méthodes communes `attached` ou `detached` étaient utilisées à la place).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/fr/@meta.texy b/component-model/fr/@meta.texy
new file mode 100644
index 0000000000..95ec8a4ef6
--- /dev/null
+++ b/component-model/fr/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentation Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/hu/@home.texy b/component-model/hu/@home.texy
index 965977e0d3..5ea05ef999 100644
--- a/component-model/hu/@home.texy
+++ b/component-model/hu/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
és amint az űrlap elérhetővé válik, a callback meghívódik. (Korábban helyette a közös `attached`, illetve `detached` metódust használták).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/hu/@meta.texy b/component-model/hu/@meta.texy
new file mode 100644
index 0000000000..c00a2158aa
--- /dev/null
+++ b/component-model/hu/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette dokumentáció}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/it/@home.texy b/component-model/it/@home.texy
index df5f1609c0..77d7b09509 100644
--- a/component-model/it/@home.texy
+++ b/component-model/it/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
e non appena il form è disponibile, viene chiamato il callback. (In passato, al suo posto venivano usati i metodi comuni `attached` rispettivamente `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/it/@meta.texy b/component-model/it/@meta.texy
new file mode 100644
index 0000000000..9d19e7312c
--- /dev/null
+++ b/component-model/it/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentazione Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/ja/@home.texy b/component-model/ja/@home.texy
index 75e45c019e..6f62c85626 100644
--- a/component-model/ja/@home.texy
+++ b/component-model/ja/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
そして、フォームが利用可能になるとすぐに、コールバックが呼び出されます。(以前は、代わりに共通のメソッド `attached` または `detached` が使用されていました)。
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/ja/@meta.texy b/component-model/ja/@meta.texy
new file mode 100644
index 0000000000..7d67dcb7b8
--- /dev/null
+++ b/component-model/ja/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette ドキュメンテーション}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/pl/@home.texy b/component-model/pl/@home.texy
index cd145ddecf..b20f94a1f3 100644
--- a/component-model/pl/@home.texy
+++ b/component-model/pl/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
a gdy formularz jest dostępny, wywoływany jest callback. (Wcześniej zamiast niego używano wspólnej metody `attached` lub `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/pl/@meta.texy b/component-model/pl/@meta.texy
new file mode 100644
index 0000000000..08f2227fb5
--- /dev/null
+++ b/component-model/pl/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Dokumentacja Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/pt/@home.texy b/component-model/pt/@home.texy
index 95ddee0a42..2e57ace611 100644
--- a/component-model/pt/@home.texy
+++ b/component-model/pt/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
e assim que o formulário estiver disponível, o callback é chamado. (Anteriormente, os métodos comuns `attached` e `detached` eram usados em seu lugar).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/pt/@meta.texy b/component-model/pt/@meta.texy
new file mode 100644
index 0000000000..e2566bcb44
--- /dev/null
+++ b/component-model/pt/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentação Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/ro/@home.texy b/component-model/ro/@home.texy
index 48b9bd6a3f..6bf15157b2 100644
--- a/component-model/ro/@home.texy
+++ b/component-model/ro/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
și de îndată ce formularul este disponibil, se apelează callback-ul. (Anterior, în locul său se folosea metoda comună `attached` respectiv `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/ro/@meta.texy b/component-model/ro/@meta.texy
new file mode 100644
index 0000000000..6554692600
--- /dev/null
+++ b/component-model/ro/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Documentație Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/ru/@home.texy b/component-model/ru/@home.texy
index e913d4f1a3..2b89ffd9fb 100644
--- a/component-model/ru/@home.texy
+++ b/component-model/ru/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
и как только форма становится доступной, вызывается callback. (Раньше вместо него использовался общий метод `attached` соответственно `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/ru/@meta.texy b/component-model/ru/@meta.texy
new file mode 100644
index 0000000000..61577d6323
--- /dev/null
+++ b/component-model/ru/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документация Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/sl/@home.texy b/component-model/sl/@home.texy
index f9804ff454..cc2bd1f48c 100644
--- a/component-model/sl/@home.texy
+++ b/component-model/sl/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
in takoj ko je obrazec na voljo, se pokliče povratni klic. (Prej se je namesto njega uporabljala skupna metoda `attached` oz. `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/sl/@meta.texy b/component-model/sl/@meta.texy
new file mode 100644
index 0000000000..282883a3d6
--- /dev/null
+++ b/component-model/sl/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokumentacija}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/tr/@home.texy b/component-model/tr/@home.texy
index 227f2b35c1..8b8015cab4 100644
--- a/component-model/tr/@home.texy
+++ b/component-model/tr/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
ve form kullanılabilir olduğunda, geri çağrı çağrılır. (Daha önce bunun yerine ortak `attached` veya `detached` yöntemi kullanılıyordu).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/tr/@meta.texy b/component-model/tr/@meta.texy
new file mode 100644
index 0000000000..e5c5cea355
--- /dev/null
+++ b/component-model/tr/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Nette Dokümantasyonu}}
+{{leftbar: nette:@menu-topics}}
diff --git a/component-model/uk/@home.texy b/component-model/uk/@home.texy
index 9b9ac7c257..34b27ba85e 100644
--- a/component-model/uk/@home.texy
+++ b/component-model/uk/@home.texy
@@ -65,6 +65,3 @@ class UploadControl extends Nette\Forms\Controls\BaseControl
```
і як тільки форма стає доступною, викликається callback. (Раніше замість нього використовувалися спільні методи `attached` або `detached`).
-
-
-{{leftbar: nette:@menu-topics}}
diff --git a/component-model/uk/@meta.texy b/component-model/uk/@meta.texy
new file mode 100644
index 0000000000..083a8ab9f7
--- /dev/null
+++ b/component-model/uk/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документація Nette}}
+{{leftbar: nette:@menu-topics}}
diff --git a/contributing/bg/syntax.texy b/contributing/bg/syntax.texy
index 23db082cf4..94bbb02a7a 100644
--- a/contributing/bg/syntax.texy
+++ b/contributing/bg/syntax.texy
@@ -1,7 +1,7 @@
Синтаксис на документацията
***************************
-Документацията използва Markdown & [синтаксис на Texy |https://texy.info/cs/syntax] с някои разширения.
+Документацията използва Markdown & [синтаксис на Texy |https://texy.nette.org/syntax] с някои разширения.
Връзки
diff --git a/contributing/cs/coding-standard.texy b/contributing/cs/coding-standard.texy
index d9e3cc8c85..5bac29274f 100644
--- a/contributing/cs/coding-standard.texy
+++ b/contributing/cs/coding-standard.texy
@@ -14,7 +14,7 @@ Obecná pravidla
- Dva prázdné řádky se používají k oddělení metod pro lepší čitelnost.
- Důvod použití shut-up operátoru musí být zdokumentován: `@mkdir($dir); // @ - adresář může existovat`.
- Pokud je použit slabě typizovaný operátor porovnání (tj. `==`, `!=`, ...), musí být zdokumentován záměr: `// == přijmout null`
-- Do jednoho souboru `exceptions.php` můžete zapsat více výjimek.
+- Do jednoho souboru `exceptions.php` můžete zapsat více výjimek, do souboru `enums.php` více enumů.
- U rozhraní se nespecifikuje viditelnost metod, protože jsou vždy veřejné.
- Každá property, návratová hodnota a parametr musí mít uvedený typ. Naopak u finálních konstant typ nikdy neuvádíme, protože je zjevný.
- K ohraničení řetězce by se měly používat jednoduché uvozovky, s výjimkou případů, kdy samotný literál obsahuje apostrofy.
@@ -109,6 +109,23 @@ public function find(string $dir, array $options): array
```
+Globální funkce a konstanty
+===========================
+
+Globální funkce a konstanty se píší bez úvodního zpětného lomítka, tedy `count($arr)` nikoliv `\count($arr)`. Pro funkce, které umí PHP optimalizovat, uvedeme na začátku souboru `use function`, aby je kompilátor mohl přeložit efektivněji. Jedná se zejména o funkce jako `count`, `strlen`, `is_array`, `is_string`, `is_scalar`, `sprintf` aj. Funkce se uvádějí na jednom řádku, aby úvodní blok importů nebyl zbytečně velký:
+
+```php
+use Nette;
+use function count, is_array, is_scalar, sprintf;
+```
+
+Výjimečně takto uvádíme i konstanty, u kterých může znalost hodnoty posloužit kompilátoru:
+
+```php
+use const PHP_OS_FAMILY;
+```
+
+
Tabulátory místo mezer
======================
diff --git a/contributing/cs/syntax.texy b/contributing/cs/syntax.texy
index ad8f3ea4c1..039f8c32ac 100644
--- a/contributing/cs/syntax.texy
+++ b/contributing/cs/syntax.texy
@@ -1,7 +1,7 @@
Dokumentační syntax
*******************
-Dokumentace používá Markdown & [Texy syntaxi |https://texy.info/cs/syntax] s některými rozšířeními.
+Dokumentace používá Markdown & [Texy syntaxi |https://texy.nette.org/syntax] s některými rozšířeními.
Odkazy
diff --git a/contributing/de/syntax.texy b/contributing/de/syntax.texy
index 64257e971f..02b8af3554 100644
--- a/contributing/de/syntax.texy
+++ b/contributing/de/syntax.texy
@@ -1,7 +1,7 @@
Dokumentationssyntax
********************
-Die Dokumentation verwendet Markdown & [Texy-Syntax |https://texy.info/de/syntax] mit einigen Erweiterungen.
+Die Dokumentation verwendet Markdown & [Texy-Syntax |https://texy.nette.org/syntax] mit einigen Erweiterungen.
Links
diff --git a/contributing/el/syntax.texy b/contributing/el/syntax.texy
index 8727317430..2f46730e28 100644
--- a/contributing/el/syntax.texy
+++ b/contributing/el/syntax.texy
@@ -1,7 +1,7 @@
Σύνταξη Τεκμηρίωσης
*******************
-Η τεκμηρίωση χρησιμοποιεί Markdown & [σύνταξη Texy |https://texy.info/cs/syntax] με ορισμένες επεκτάσεις.
+Η τεκμηρίωση χρησιμοποιεί Markdown & [σύνταξη Texy |https://texy.nette.org/syntax] με ορισμένες επεκτάσεις.
Σύνδεσμοι
diff --git a/contributing/en/coding-standard.texy b/contributing/en/coding-standard.texy
index e98f821d4d..2883d9634d 100644
--- a/contributing/en/coding-standard.texy
+++ b/contributing/en/coding-standard.texy
@@ -14,7 +14,7 @@ General Rules
- Two empty lines are used to separate methods for better readability
- The reason for using the shut-up operator (`@`) must be documented: `@mkdir($dir); // @ - directory may exist`
- If a weak typed comparison operator is used (i.e., `==`, `!=`, ...), the intention must be documented: `// == to accept null`
-- You can write multiple exception classes into a single file named `exceptions.php`
+- You can write multiple exception classes into a single file named `exceptions.php`, and multiple enums into `enums.php`
- The visibility of methods is not specified for interfaces because they are always public
- Each property, return value, and parameter must have a type specified. Conversely, for final constants, we never specify the type because it is obvious
- Single quotes should be used to delimit strings, except when the literal itself contains apostrophes
@@ -109,6 +109,23 @@ public function find(string $dir, array $options): array
```
+Global Functions and Constants
+==============================
+
+Global functions and constants are written without a leading backslash, i.e., `count($arr)` not `\count($arr)`. For functions that PHP can optimize, add `use function` at the beginning of the file so the compiler can translate them more efficiently. These include functions like `count`, `strlen`, `is_array`, `is_string`, `is_scalar`, `sprintf`, etc. Functions are listed on a single line to keep the import block compact:
+
+```php
+use Nette;
+use function count, is_array, is_scalar, sprintf;
+```
+
+Occasionally, we also import constants whose value knowledge may help the compiler:
+
+```php
+use const PHP_OS_FAMILY;
+```
+
+
Tabs Instead of Spaces
======================
diff --git a/contributing/en/syntax.texy b/contributing/en/syntax.texy
index a04894a8b9..c7d81ac54f 100644
--- a/contributing/en/syntax.texy
+++ b/contributing/en/syntax.texy
@@ -1,7 +1,7 @@
Documentation Syntax
********************
-Documentation uses Markdown & [Texy syntax |https://texy.info/en/syntax] with several enhancements.
+Documentation uses Markdown & [Texy syntax |https://texy.nette.org/syntax] with several enhancements.
Links
diff --git a/contributing/es/syntax.texy b/contributing/es/syntax.texy
index 97d8316c1c..559dc80217 100644
--- a/contributing/es/syntax.texy
+++ b/contributing/es/syntax.texy
@@ -1,7 +1,7 @@
Sintaxis de la documentación
****************************
-La documentación utiliza Markdown y la [sintaxis Texy |https://texy.info/cs/syntax] con algunas extensiones.
+La documentación utiliza Markdown y la [sintaxis Texy |https://texy.nette.org/syntax] con algunas extensiones.
Enlaces
diff --git a/contributing/fr/syntax.texy b/contributing/fr/syntax.texy
index 29c724851e..9b6df676f7 100644
--- a/contributing/fr/syntax.texy
+++ b/contributing/fr/syntax.texy
@@ -1,7 +1,7 @@
Syntaxe de la documentation
***************************
-La documentation utilise Markdown & la [syntaxe Texy |https://texy.info/cs/syntax] avec quelques extensions.
+La documentation utilise Markdown & la [syntaxe Texy |https://texy.nette.org/syntax] avec quelques extensions.
Liens
diff --git a/contributing/hu/syntax.texy b/contributing/hu/syntax.texy
index 66b8b50260..11e46f6417 100644
--- a/contributing/hu/syntax.texy
+++ b/contributing/hu/syntax.texy
@@ -1,7 +1,7 @@
Dokumentációs szintaxis
***********************
-A dokumentáció Markdown & [Texy szintaxist |https://texy.info/cs/syntax] használ néhány kiterjesztéssel.
+A dokumentáció Markdown & [Texy szintaxist |https://texy.nette.org/syntax] használ néhány kiterjesztéssel.
Linkek
diff --git a/contributing/it/syntax.texy b/contributing/it/syntax.texy
index ef704f10e4..c60a00fb10 100644
--- a/contributing/it/syntax.texy
+++ b/contributing/it/syntax.texy
@@ -1,7 +1,7 @@
Sintassi della documentazione
*****************************
-La documentazione utilizza Markdown e la [sintassi Texy |https://texy.info/cs/syntax] con alcune estensioni.
+La documentazione utilizza Markdown e la [sintassi Texy |https://texy.nette.org/syntax] con alcune estensioni.
Link
diff --git a/contributing/ja/syntax.texy b/contributing/ja/syntax.texy
index 4ee286ef64..2fe4e0c515 100644
--- a/contributing/ja/syntax.texy
+++ b/contributing/ja/syntax.texy
@@ -1,7 +1,7 @@
ドキュメント構文
********
-ドキュメントはMarkdownと [Texy構文 |https://texy.info/cs/syntax] を使用し、いくつかの拡張機能があります。
+ドキュメントはMarkdownと [Texy構文 |https://texy.nette.org/syntax] を使用し、いくつかの拡張機能があります。
リンク
diff --git a/contributing/pl/syntax.texy b/contributing/pl/syntax.texy
index 0090da8000..08b4227f42 100644
--- a/contributing/pl/syntax.texy
+++ b/contributing/pl/syntax.texy
@@ -1,7 +1,7 @@
Składnia dokumentacji
*********************
-Dokumentacja używa składni Markdown & [składni Texy |https://texy.info/cs/syntax] z niektórymi rozszerzeniami.
+Dokumentacja używa składni Markdown & [składni Texy |https://texy.nette.org/syntax] z niektórymi rozszerzeniami.
Linki
diff --git a/contributing/pt/syntax.texy b/contributing/pt/syntax.texy
index c820a98389..e810926f67 100644
--- a/contributing/pt/syntax.texy
+++ b/contributing/pt/syntax.texy
@@ -1,7 +1,7 @@
Sintaxe da Documentação
***********************
-A documentação usa Markdown e a [sintaxe Texy |https://texy.info/cs/syntax] com algumas extensões.
+A documentação usa Markdown e a [sintaxe Texy |https://texy.nette.org/syntax] com algumas extensões.
Links
diff --git a/contributing/ro/syntax.texy b/contributing/ro/syntax.texy
index dd1a95cf97..d756e4e2b0 100644
--- a/contributing/ro/syntax.texy
+++ b/contributing/ro/syntax.texy
@@ -1,7 +1,7 @@
Sintaxa documentației
*********************
-Documentația utilizează Markdown & [sintaxa Texy |https://texy.info/en/syntax] cu unele extensii.
+Documentația utilizează Markdown & [sintaxa Texy |https://texy.nette.org/syntax] cu unele extensii.
Linkuri
diff --git a/contributing/ru/syntax.texy b/contributing/ru/syntax.texy
index ad1bbc8511..af9411a740 100644
--- a/contributing/ru/syntax.texy
+++ b/contributing/ru/syntax.texy
@@ -1,7 +1,7 @@
Синтаксис документации
**********************
-Документация использует синтаксис Markdown и [синтаксис Texy |https://texy.info/cs/syntax] с некоторыми расширениями.
+Документация использует синтаксис Markdown и [синтаксис Texy |https://texy.nette.org/syntax] с некоторыми расширениями.
Ссылки
diff --git a/contributing/sl/syntax.texy b/contributing/sl/syntax.texy
index 8486f3ea0e..55aed5ac18 100644
--- a/contributing/sl/syntax.texy
+++ b/contributing/sl/syntax.texy
@@ -1,7 +1,7 @@
Sintaksa dokumentacije
**********************
-Dokumentacija uporablja Markdown & [sintakso Texy |https://texy.info/sl/syntax] z nekaterimi razširitvami.
+Dokumentacija uporablja Markdown & [sintakso Texy |https://texy.nette.org/syntax] z nekaterimi razširitvami.
Povezave
diff --git a/contributing/tr/syntax.texy b/contributing/tr/syntax.texy
index 650cfe37eb..41bbf226ef 100644
--- a/contributing/tr/syntax.texy
+++ b/contributing/tr/syntax.texy
@@ -1,7 +1,7 @@
Dokümantasyon sözdizimi
***********************
-Dokümantasyon, bazı uzantılarla birlikte Markdown & [Texy sözdizimini |https://texy.info/cs/syntax] kullanır.
+Dokümantasyon, bazı uzantılarla birlikte Markdown & [Texy sözdizimini |https://texy.nette.org/syntax] kullanır.
Bağlantılar
diff --git a/contributing/uk/syntax.texy b/contributing/uk/syntax.texy
index de3c97be92..c9d1b66d60 100644
--- a/contributing/uk/syntax.texy
+++ b/contributing/uk/syntax.texy
@@ -1,7 +1,7 @@
Синтаксис документації
**********************
-Документація використовує Markdown та [синтаксис Texy |https://texy.info/cs/syntax] з деякими розширеннями.
+Документація використовує Markdown та [синтаксис Texy |https://texy.nette.org/syntax] з деякими розширеннями.
Посилання
diff --git a/database/bg/@home.texy b/database/bg/@home.texy
index 3dfb819140..7eccf1677b 100644
--- a/database/bg/@home.texy
+++ b/database/bg/@home.texy
@@ -17,5 +17,5 @@ Nette поддържа следните бази данни:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database значително улеснява извличането на данни от базата данни, без да е необходимо да се пишат SQL заявки. Изпълнява ефективни заявки и не прехвърля излишни данни.}}
diff --git a/database/bg/@meta.texy b/database/bg/@meta.texy
new file mode 100644
index 0000000000..57804a1127
--- /dev/null
+++ b/database/bg/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация на Nette}}
diff --git a/database/cs/@home.texy b/database/cs/@home.texy
index 20cc87170b..58162d133d 100644
--- a/database/cs/@home.texy
+++ b/database/cs/@home.texy
@@ -17,5 +17,5 @@ Nette podporuje následující databáze:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database zásadním způsobem zjednodušuje získávání dat z databáze bez nutnosti psát SQL dotazy. Pokládá efektivní dotazy a nepřenáší zbytečná data.}}
diff --git a/database/cs/@meta.texy b/database/cs/@meta.texy
new file mode 100644
index 0000000000..462d9add80
--- /dev/null
+++ b/database/cs/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentace}}
diff --git a/database/cs/explorer.texy b/database/cs/explorer.texy
index 24044ef827..646e033f48 100644
--- a/database/cs/explorer.texy
+++ b/database/cs/explorer.texy
@@ -263,7 +263,7 @@ Usnadňuje stránkování výsledků. Přijímá číslo stránky (počítané o
```php
$numOfPages = null;
-$table->page(page: 3, itemsPerPage: 10, $numOfPages);
+$table->page(page: 3, itemsPerPage: 10, numOfPages: $numOfPages);
echo "Celkem stránek: $numOfPages";
```
diff --git a/database/de/@home.texy b/database/de/@home.texy
index 90353a0fcb..45a96f08ed 100644
--- a/database/de/@home.texy
+++ b/database/de/@home.texy
@@ -17,5 +17,5 @@ Nette unterstützt die folgenden Datenbanken:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database vereinfacht das Abrufen von Daten aus der Datenbank erheblich, ohne dass SQL-Abfragen geschrieben werden müssen. Es stellt effiziente Abfragen und überträgt keine unnötigen Daten.}}
diff --git a/database/de/@meta.texy b/database/de/@meta.texy
new file mode 100644
index 0000000000..b3b806b2ca
--- /dev/null
+++ b/database/de/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentation}}
diff --git a/database/el/@home.texy b/database/el/@home.texy
index d97c6395c8..ff1b599908 100644
--- a/database/el/@home.texy
+++ b/database/el/@home.texy
@@ -17,5 +17,5 @@
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Η Nette Database απλοποιεί σημαντικά την ανάκτηση δεδομένων από τη βάση δεδομένων χωρίς την ανάγκη γραφής ερωτημάτων SQL. Θέτει αποτελεσματικά ερωτήματα και δεν μεταφέρει περιττά δεδομένα.}}
diff --git a/database/el/@meta.texy b/database/el/@meta.texy
new file mode 100644
index 0000000000..88e29852c7
--- /dev/null
+++ b/database/el/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Τεκμηρίωση}}
diff --git a/database/en/@home.texy b/database/en/@home.texy
index 7b34e23d7a..7d7452d8d1 100644
--- a/database/en/@home.texy
+++ b/database/en/@home.texy
@@ -16,5 +16,5 @@ These database servers are supported:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database significantly simplifies retrieving data from the database without writing SQL queries. It executes efficient queries and does not transfer unnecessary data.}}
diff --git a/database/en/@meta.texy b/database/en/@meta.texy
new file mode 100644
index 0000000000..42471908b0
--- /dev/null
+++ b/database/en/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentation}}
diff --git a/database/en/explorer.texy b/database/en/explorer.texy
index dc5e7ef7af..d08f43a51e 100644
--- a/database/en/explorer.texy
+++ b/database/en/explorer.texy
@@ -263,7 +263,7 @@ Facilitates pagination of results. It accepts the page number (starting from 1)
```php
$numOfPages = null;
-$table->page(page: 3, itemsPerPage: 10, $numOfPages);
+$table->page(page: 3, itemsPerPage: 10, numOfPages: $numOfPages);
echo "Total pages: $numOfPages";
```
diff --git a/database/es/@home.texy b/database/es/@home.texy
index 62e054c191..847f8e4d76 100644
--- a/database/es/@home.texy
+++ b/database/es/@home.texy
@@ -17,5 +17,5 @@ Nette soporta las siguientes bases de datos:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database simplifica radicalmente la obtención de datos de la base de datos sin necesidad de escribir consultas SQL. Realiza consultas eficientes y no transfiere datos innecesarios.}}
diff --git a/database/es/@meta.texy b/database/es/@meta.texy
new file mode 100644
index 0000000000..1670b124ad
--- /dev/null
+++ b/database/es/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentación}}
diff --git a/database/fr/@home.texy b/database/fr/@home.texy
index 672d9bd648..f05b61a24f 100644
--- a/database/fr/@home.texy
+++ b/database/fr/@home.texy
@@ -17,5 +17,5 @@ Nette prend en charge les bases de données suivantes :
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database simplifie considérablement l'obtention de données de la base de données sans avoir à écrire de requêtes SQL. Il exécute des requêtes efficaces et ne transfère pas de données inutiles.}}
diff --git a/database/fr/@meta.texy b/database/fr/@meta.texy
new file mode 100644
index 0000000000..72ae4b8db8
--- /dev/null
+++ b/database/fr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentation Nette}}
diff --git a/database/hu/@home.texy b/database/hu/@home.texy
index 07b7d2f61b..fc880e7b35 100644
--- a/database/hu/@home.texy
+++ b/database/hu/@home.texy
@@ -17,5 +17,5 @@ A Nette a következő adatbázisokat támogatja:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: A Nette Database jelentősen leegyszerűsíti az adatok lekérdezését az adatbázisból SQL lekérdezések írása nélkül. Hatékony lekérdezéseket tesz és nem továbbít felesleges adatokat.}}
diff --git a/database/hu/@meta.texy b/database/hu/@meta.texy
new file mode 100644
index 0000000000..c172d1cda5
--- /dev/null
+++ b/database/hu/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette dokumentáció}}
diff --git a/database/it/@home.texy b/database/it/@home.texy
index 265f5cc820..97f1e1e9db 100644
--- a/database/it/@home.texy
+++ b/database/it/@home.texy
@@ -17,5 +17,5 @@ Nette supporta i seguenti database:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database semplifica notevolmente l'ottenimento di dati dal database senza la necessità di scrivere query SQL. Esegue query efficienti e non trasferisce dati inutili.}}
diff --git a/database/it/@meta.texy b/database/it/@meta.texy
new file mode 100644
index 0000000000..4647d0c8a2
--- /dev/null
+++ b/database/it/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentazione Nette}}
diff --git a/database/ja/@home.texy b/database/ja/@home.texy
index 121b7c37e7..965d3ecec8 100644
--- a/database/ja/@home.texy
+++ b/database/ja/@home.texy
@@ -17,5 +17,5 @@ Netteは以下のデータベースをサポートしています:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Databaseは、SQLクエリを記述する必要なく、データベースからデータを取得するプロセスを大幅に簡素化します。効率的なクエリを実行し、不要なデータを転送しません。}}
diff --git a/database/ja/@meta.texy b/database/ja/@meta.texy
new file mode 100644
index 0000000000..d3c41dc3d7
--- /dev/null
+++ b/database/ja/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette ドキュメンテーション}}
diff --git a/database/pl/@home.texy b/database/pl/@home.texy
index 25f116f77f..4093fa6893 100644
--- a/database/pl/@home.texy
+++ b/database/pl/@home.texy
@@ -17,5 +17,5 @@ Nette obsługuje następujące bazy danych:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database w znaczący sposób upraszcza pobieranie danych z bazy danych bez konieczności pisania zapytań SQL. Składa efektywne zapytania i nie przesyła zbędnych danych.}}
diff --git a/database/pl/@meta.texy b/database/pl/@meta.texy
new file mode 100644
index 0000000000..61ac92d1af
--- /dev/null
+++ b/database/pl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Dokumentacja Nette}}
diff --git a/database/pt/@home.texy b/database/pt/@home.texy
index ae5a1cc937..dc4308eeae 100644
--- a/database/pt/@home.texy
+++ b/database/pt/@home.texy
@@ -17,5 +17,5 @@ Nette suporta os seguintes bancos de dados:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database simplifica significativamente a obtenção de dados do banco de dados sem a necessidade de escrever consultas SQL. Ele faz consultas eficientes e não transfere dados desnecessários.}}
diff --git a/database/pt/@meta.texy b/database/pt/@meta.texy
new file mode 100644
index 0000000000..41a853b6aa
--- /dev/null
+++ b/database/pt/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentação Nette}}
diff --git a/database/ro/@home.texy b/database/ro/@home.texy
index 9a10cbe9b0..e6e3ddb3ab 100644
--- a/database/ro/@home.texy
+++ b/database/ro/@home.texy
@@ -17,5 +17,5 @@ Nette suportă următoarele baze de date:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database simplifică semnificativ recuperarea datelor din baza de date fără a fi nevoie să scrieți interogări SQL. Execută interogări eficiente și nu transferă date inutile.}}
diff --git a/database/ro/@meta.texy b/database/ro/@meta.texy
new file mode 100644
index 0000000000..9c744b37d6
--- /dev/null
+++ b/database/ro/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentație Nette}}
diff --git a/database/ru/@home.texy b/database/ru/@home.texy
index 6753a2c576..0927782214 100644
--- a/database/ru/@home.texy
+++ b/database/ru/@home.texy
@@ -17,5 +17,5 @@ Nette поддерживает следующие базы данных:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database существенно упрощает получение данных из базы данных без необходимости писать SQL-запросы. Он выполняет эффективные запросы и не передает лишние данные.}}
diff --git a/database/ru/@meta.texy b/database/ru/@meta.texy
new file mode 100644
index 0000000000..7f329adfce
--- /dev/null
+++ b/database/ru/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация Nette}}
diff --git a/database/sl/@home.texy b/database/sl/@home.texy
index 0cca97ba14..5c0ffe069e 100644
--- a/database/sl/@home.texy
+++ b/database/sl/@home.texy
@@ -17,5 +17,5 @@ Nette podpira naslednje podatkovne baze:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database bistveno poenostavlja pridobivanje podatkov iz podatkovne baze brez potrebe po pisanju SQL poizvedb. Postavlja učinkovite poizvedbe in ne prenaša nepotrebnih podatkov.}}
diff --git a/database/sl/@meta.texy b/database/sl/@meta.texy
new file mode 100644
index 0000000000..724324bee5
--- /dev/null
+++ b/database/sl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentacija}}
diff --git a/database/tr/@home.texy b/database/tr/@home.texy
index aeb01502ee..7700df2b84 100644
--- a/database/tr/@home.texy
+++ b/database/tr/@home.texy
@@ -17,5 +17,5 @@ Nette aşağıdaki veritabanlarını destekler:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database, SQL sorguları yazmaya gerek kalmadan veritabanından veri almayı önemli ölçüde basitleştirir. Etkili sorgular yapar ve gereksiz verileri aktarmaz.}}
diff --git a/database/tr/@meta.texy b/database/tr/@meta.texy
new file mode 100644
index 0000000000..8dfe82f311
--- /dev/null
+++ b/database/tr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokümantasyonu}}
diff --git a/database/uk/@home.texy b/database/uk/@home.texy
index 195714c91a..9cd3b93223 100644
--- a/database/uk/@home.texy
+++ b/database/uk/@home.texy
@@ -17,5 +17,5 @@ Nette підтримує наступні бази даних:
-{{title: Nette Database}}
+{{maintitle: Nette Database - awesome database layer for PHP}}
{{description: Nette Database суттєво спрощує отримання даних з бази даних без необхідності писати SQL-запити. Вона виконує ефективні запити та не передає зайвих даних.}}
diff --git a/database/uk/@meta.texy b/database/uk/@meta.texy
new file mode 100644
index 0000000000..96e2d9752a
--- /dev/null
+++ b/database/uk/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документація Nette}}
diff --git a/dependency-injection/bg/@meta.texy b/dependency-injection/bg/@meta.texy
new file mode 100644
index 0000000000..57804a1127
--- /dev/null
+++ b/dependency-injection/bg/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация на Nette}}
diff --git a/dependency-injection/cs/@meta.texy b/dependency-injection/cs/@meta.texy
new file mode 100644
index 0000000000..462d9add80
--- /dev/null
+++ b/dependency-injection/cs/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentace}}
diff --git a/dependency-injection/cs/factory.texy b/dependency-injection/cs/factory.texy
index 205b3655fd..a90573d587 100644
--- a/dependency-injection/cs/factory.texy
+++ b/dependency-injection/cs/factory.texy
@@ -173,7 +173,7 @@ interface MultiFactory
}
```
-Takže místo toho, abych si předávali několik generovaných továren a accessorů, předáme jednu komplexnější továrnu, která toho umí víc.
+Takže místo toho, abychom si předávali několik generovaných továren a accessorů, předáme jednu komplexnější továrnu, která toho umí víc.
Alternativně lze místo několika metod použít `get()` s parameterem:
diff --git a/dependency-injection/cs/faq.texy b/dependency-injection/cs/faq.texy
index e9842c0bba..a64b806cbe 100644
--- a/dependency-injection/cs/faq.texy
+++ b/dependency-injection/cs/faq.texy
@@ -88,7 +88,7 @@ Mějme na paměti [Pravidlo č. 1: nech si to předat |introduction#Pravidlo č.
V této ukázce je `%myParameter%` zástupný symbol pro hodnotu parametru `myParameter`, který se předá do konstruktoru třídy `MyClass`:
-```php
+```neon
# config.neon
parameters:
myParameter: Some value
diff --git a/dependency-injection/cs/global-state.texy b/dependency-injection/cs/global-state.texy
index d152d69973..2f7ddf5caf 100644
--- a/dependency-injection/cs/global-state.texy
+++ b/dependency-injection/cs/global-state.texy
@@ -93,7 +93,7 @@ Musíte podrobně procházet kód, abyste zjistili, že objekt `PaymentGateway`
```php
$db = new DB('mysql:', 'user', 'password');
-$gateway = new PaymentGateway($db, ...);
+$gateway = new PaymentGateway($db, /* ... */);
```
Podobný problém se objevuje i při použití globálního přístupu k databázovému spojení:
diff --git a/dependency-injection/cs/services.texy b/dependency-injection/cs/services.texy
index 10c8e6ac30..6f4ec1bacb 100644
--- a/dependency-injection/cs/services.texy
+++ b/dependency-injection/cs/services.texy
@@ -181,7 +181,7 @@ public function createServiceFoo(): Foo
{
$service = new Foo;
$service->value = 123;
- $service->onClick[] = [$this->getService('bar'), 'clickHandler'];
+ $service->onClick[] = $this->getService('bar')->clickHandler(...);
return $service;
}
```
@@ -381,7 +381,7 @@ services:
logger: monolog.logger.event
```
-Aby jste získali všechny služby s určitými tagy, můžete použít funkci `tagged()`:
+Abyste získali všechny služby s určitými tagy, můžete použít funkci `tagged()`:
```neon
services:
@@ -433,8 +433,14 @@ services:
application.application:
create: MyApplication
alteration: true
- setup:
- - '$onStartup[]' = [@resource, init]
+```
+
+Službu nemusíte identifikovat interním názvem, můžete na ni odkázat i jejím typem. Předchozí příklad tak lze zapsat i takto:
+
+```neon
+services:
+ @Nette\Application\Application:
+ create: MyApplication
```
Při přepisování služby můžeme chtít odstranit původní argumenty, položky setup nebo tagy, k čemuž slouží `reset`:
diff --git a/dependency-injection/de/@meta.texy b/dependency-injection/de/@meta.texy
new file mode 100644
index 0000000000..b3b806b2ca
--- /dev/null
+++ b/dependency-injection/de/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentation}}
diff --git a/dependency-injection/el/@meta.texy b/dependency-injection/el/@meta.texy
new file mode 100644
index 0000000000..88e29852c7
--- /dev/null
+++ b/dependency-injection/el/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Τεκμηρίωση}}
diff --git a/dependency-injection/en/@meta.texy b/dependency-injection/en/@meta.texy
new file mode 100644
index 0000000000..42471908b0
--- /dev/null
+++ b/dependency-injection/en/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentation}}
diff --git a/dependency-injection/en/faq.texy b/dependency-injection/en/faq.texy
index b7f65321ba..6f8b836dc9 100644
--- a/dependency-injection/en/faq.texy
+++ b/dependency-injection/en/faq.texy
@@ -88,7 +88,7 @@ Keep in mind [Rule #1: Let It Be Passed to You |introduction#Rule #1: Let It Be
In this example, `%myParameter%` is a placeholder for the value of the `myParameter` parameter, which will be passed to the `MyClass` constructor:
-```php
+```neon
# config.neon
parameters:
myParameter: Some value
diff --git a/dependency-injection/en/global-state.texy b/dependency-injection/en/global-state.texy
index f626392831..794f2814b3 100644
--- a/dependency-injection/en/global-state.texy
+++ b/dependency-injection/en/global-state.texy
@@ -93,7 +93,7 @@ You must meticulously trace the code to discover that the `PaymentGateway` objec
```php
$db = new DB('mysql:', 'user', 'password');
-$gateway = new PaymentGateway($db, ...);
+$gateway = new PaymentGateway($db, /* ... */);
```
A similar problem arises when using global access to a database connection:
diff --git a/dependency-injection/en/services.texy b/dependency-injection/en/services.texy
index 7b3ad6b364..8da30d74ed 100644
--- a/dependency-injection/en/services.texy
+++ b/dependency-injection/en/services.texy
@@ -181,7 +181,7 @@ public function createServiceFoo(): Foo
{
$service = new Foo;
$service->value = 123;
- $service->onClick[] = [$this->getService('bar'), 'clickHandler'];
+ $service->onClick[] = $this->getService('bar')->clickHandler(...);
return $service;
}
```
@@ -433,8 +433,14 @@ services:
application.application:
create: MyApplication
alteration: true
- setup:
- - '$onStartup[]' = [@resource, init]
+```
+
+You don't have to identify a service by its internal name — you can refer to it by type instead. The previous example can also be written as:
+
+```neon
+services:
+ @Nette\Application\Application:
+ create: MyApplication
```
When modifying a service, we might want to remove original arguments, setup items, or tags, using the `reset` key:
diff --git a/dependency-injection/es/@meta.texy b/dependency-injection/es/@meta.texy
new file mode 100644
index 0000000000..1670b124ad
--- /dev/null
+++ b/dependency-injection/es/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentación}}
diff --git a/dependency-injection/fr/@meta.texy b/dependency-injection/fr/@meta.texy
new file mode 100644
index 0000000000..72ae4b8db8
--- /dev/null
+++ b/dependency-injection/fr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentation Nette}}
diff --git a/dependency-injection/hu/@meta.texy b/dependency-injection/hu/@meta.texy
new file mode 100644
index 0000000000..c172d1cda5
--- /dev/null
+++ b/dependency-injection/hu/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette dokumentáció}}
diff --git a/dependency-injection/it/@meta.texy b/dependency-injection/it/@meta.texy
new file mode 100644
index 0000000000..4647d0c8a2
--- /dev/null
+++ b/dependency-injection/it/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentazione Nette}}
diff --git a/dependency-injection/ja/@meta.texy b/dependency-injection/ja/@meta.texy
new file mode 100644
index 0000000000..d3c41dc3d7
--- /dev/null
+++ b/dependency-injection/ja/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette ドキュメンテーション}}
diff --git a/dependency-injection/pl/@meta.texy b/dependency-injection/pl/@meta.texy
new file mode 100644
index 0000000000..61ac92d1af
--- /dev/null
+++ b/dependency-injection/pl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Dokumentacja Nette}}
diff --git a/dependency-injection/pt/@meta.texy b/dependency-injection/pt/@meta.texy
new file mode 100644
index 0000000000..41a853b6aa
--- /dev/null
+++ b/dependency-injection/pt/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentação Nette}}
diff --git a/dependency-injection/ro/@meta.texy b/dependency-injection/ro/@meta.texy
new file mode 100644
index 0000000000..9c744b37d6
--- /dev/null
+++ b/dependency-injection/ro/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentație Nette}}
diff --git a/dependency-injection/ru/@meta.texy b/dependency-injection/ru/@meta.texy
new file mode 100644
index 0000000000..7f329adfce
--- /dev/null
+++ b/dependency-injection/ru/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация Nette}}
diff --git a/dependency-injection/sl/@meta.texy b/dependency-injection/sl/@meta.texy
new file mode 100644
index 0000000000..724324bee5
--- /dev/null
+++ b/dependency-injection/sl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentacija}}
diff --git a/dependency-injection/tr/@meta.texy b/dependency-injection/tr/@meta.texy
new file mode 100644
index 0000000000..8dfe82f311
--- /dev/null
+++ b/dependency-injection/tr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokümantasyonu}}
diff --git a/dependency-injection/uk/@meta.texy b/dependency-injection/uk/@meta.texy
new file mode 100644
index 0000000000..96e2d9752a
--- /dev/null
+++ b/dependency-injection/uk/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документація Nette}}
diff --git a/dibi/cs/@home.texy b/dibi/cs/@home.texy
new file mode 100644
index 0000000000..0270991509
--- /dev/null
+++ b/dibi/cs/@home.texy
@@ -0,0 +1,657 @@
+Dibi: Šikovná Database Abstraction Library pro PHP
+**************************************************
+
+Nejnovější stabilní verzi Dibi instalujte pomocí [Composer|best-practices:composer] příkazem:
+
+```
+composer require dibi/dibi
+```
+
+Přehled verzí najdete na stánce [Releases | https://github.com/dg/dibi/releases].
+
+Vyžaduje PHP 8.0 nebo vyšší.
+
+
+Připojení k databázi
+====================
+
+Databázové spojení je reprezentováno objektem [Dibi\Connection|api:]:
+
+```php
+$database = new Dibi\Connection([
+ 'driver' => 'mysqli',
+ 'host' => 'localhost',
+ 'username' => 'root',
+ 'password' => '***',
+ 'database' => 'table',
+]);
+
+$result = $database->query('SELECT * FROM users');
+```
+
+Alternativně můžete používat statický registr `dibi`, který udržuje v globálně dostupném úložišti objekt spojení a nad ním volá všechny funkce:
+
+```php
+dibi::connect([
+ 'driver' => 'mysqli',
+ 'host' => 'localhost',
+ 'username' => 'root',
+ 'password' => '***',
+ 'database' => 'test',
+ 'charset' => 'utf8',
+]);
+
+$result = dibi::query('SELECT * FROM users');
+```
+
+V případě chyby připojení se vyhodí `Dibi\Exception`.
+
+
+Dotazy
+======
+
+Databázové dotazy pokládáme metodou `query()`, která vrací [Dibi\Result |api:Dibi\Result]. Řádky jako objekty [Dibi\Row |api:Dibi\Row].
+
+Všechny příklady si můžete zkoušet [online na hřišti |https://repl.it/@DavidGrudl/dibi-playground].
+
+```php
+$result = $database->query('SELECT * FROM users');
+
+foreach ($result as $row) {
+ echo $row->id;
+ echo $row->name;
+}
+
+// pole všech řádků
+$all = $result->fetchAll();
+
+// pole všech řádků, klíčem je 'id'
+$all = $result->fetchAssoc('id');
+
+// asociativní pole id => name
+$pairs = $result->fetchPairs('id', 'name');
+
+// počet řádků výsledku, pokud je znám, nebo počet ovlivněných řádků
+$count = $result->getRowCount();
+```
+
+Metoda fetchAssoc() umí vracet i [složitější asociativní pole |#Výsledek jako asociativní pole].
+
+Do dotazu lze velmi snadno přidávat i parametry, všimněte si otazníku:
+
+```php
+$result = $database->query('SELECT * FROM users WHERE name = ? AND active = ?', $name, $active);
+
+// nebo
+$result = $database->query('SELECT * FROM users WHERE name = ?', $name, 'AND active = ?', $active);
+
+$ids = [10, 20, 30];
+$result = $database->query('SELECT * FROM users WHERE id IN (?)', $ids);
+```
+
+
+**POZOR, nikdy dotazy neskládejte jako řetězce, vznikla by zranitelnost [SQL injection |https://cs.wikipedia.org/wiki/SQL_injection]**
+/--
+$database->query('SELECT * FROM users WHERE id = ' . $id); // ŠPATNĚ!!!
+\--
+
+
+Místo otazníku lze používat i tzv. [#modifikátory].
+
+```php
+$result = $database->query('SELECT * FROM users WHERE name = %s', $name);
+```
+
+V případě selhání `query()` vyhodí buď `Dibi\Exception`, nebo některého z potomků:
+
+- [ConstraintViolationException |api:Dibi\ConstraintViolationException] - porušení nějakého omezení pro tabulku
+- [ForeignKeyConstraintViolationException |api:Dibi\ForeignKeyConstraintViolationException] - neplatný cizí klíč
+- [NotNullConstraintViolationException |api:Dibi\NotNullConstraintViolationException] - porušení podmínky NOT NULL
+- [UniqueConstraintViolationException |api:Dibi\UniqueConstraintViolationException] - koliduje unikátní index
+
+Dotazy lze pokládat také pomocí zkratek:
+
+```php
+// vrátí asociativní pole id => name, zkratka pro query(...)->fetchPairs()
+$pairs = $database->fetchPairs('SELECT id, name FROM users');
+
+// vrátí pole všech řádků, zkratka pro query(...)->fetchAll()
+$rows = $database->fetchAll('SELECT * FROM users');
+
+// vrátí řádek, zkratka pro query(...)->fetch()
+$row = $database->fetch('SELECT * FROM users WHERE id = ?', $id);
+
+// vrátí buňku, zkratka pro query(...)->fetchSingle()
+$name = $database->fetchSingle('SELECT name FROM users WHERE id = ?', $id);
+```
+
+
+Modifikátory
+============
+
+Kromě zástupného symbolu `?` můžeme používat i modifikátory:
+
+| %s | string
+| %sN | string, ale '' se přeloží jako NULL
+| %bin | binární data
+| %b | boolean
+| %i | integer
+| %iN | integer, ale 0 se přeloží jako NULL
+| %f | float
+| %d | datum (očekává DateTime, string nebo UNIX timestamp)
+| %dt | datum & čas (očekává DateTime, string nebo UNIX timestamp)
+| %n | identifikátor, tedy název tabulky či sloupce
+| %N | identifikátor, považuje tečku za běžný znak
+| %SQL | SQL - přímo vloží do SQL (alternativou je Dibi\Literal)
+| %ex | expanduje pole
+| %lmt | speciální - doplní do dotazu LIMIT
+| %ofs | speciální - doplní do dotazu OFFSET
+
+Příklad:
+
+```php
+$result = $database->query('SELECT * FROM users WHERE name = %s', $name);
+```
+
+Pokud `$name` je `null`, vloží se do SQL příkazu `NULL`.
+
+Pokud proměnná je pole, tak se modifikátor aplikuje na všechny jeho prvky a ty se vloží do SQL oddělené čárkami:
+
+```php
+$ids = [10, '20', 30];
+$result = $database->query('SELECT * FROM users WHERE id IN (%i)', $ids);
+// SELECT * FROM users WHERE id IN (10, 20, 30)
+```
+
+Modifikátor `%n` využijete v případě, že název tabulky nebo sloupce je proměnnou. (Pozor, nedovolte uživateli manipulovat s obsahem takové proměnné):
+
+```php
+$table = 'blog.users';
+$column = 'name';
+$result = $database->query('SELECT * FROM %n WHERE %n = ?', $table, $column, $value);
+// SELECT * FROM `blog`.`users` WHERE `name` = 'Jim'
+```
+
+Pro operátor LIKE jsou k dispozici čtyři speciální modifikátory:
+
+| %like~ | výraz začíná řetězcem
+| %~like | výraz končí řetězcem
+| %~like~ | výraz obsahuje řetězec
+| `%like` | výraz je řetězec
+
+Hledej jména začínající na určitý řetězec:
+
+```php
+$result = $database->query('SELECT * FROM table WHERE name LIKE %like~', $query);
+```
+
+
+Modifikátory polí
+=================
+
+Parameterem vkládaným do SQL dotazu může být i pole. Tyto modifikátory určují, jak z něj sestavit SQL příkaz:
+
+| %and | | `key1 = value1 AND key2 = value2 AND ...`
+| %or | | `key1 = value1 OR key2 = value2 OR ...`
+| %a | assoc | `key1 = value1, key2 = value2, ...`
+| %l %in | list | `(val1, val2, ...)`
+| %v | values | `(key1, key2, ...) VALUES (value1, value2, ...)`
+| %m | multi | `(key1, key2, ...) VALUES (value1, value2, ...), (value1, value2, ...), ...`
+| %by | řazení | `key1 ASC, key2 DESC ...`
+| %n | názvy | `key1, key2 AS alias, ...`
+
+Příklad:
+
+```php
+$arr = [
+ 'a' => 'hello',
+ 'b' => true,
+];
+
+$database->query('INSERT INTO table %v', $arr);
+// INSERT INTO `table` (`a`, `b`) VALUES ('hello', 1)
+
+$database->query('UPDATE `table` SET %a', $arr);
+// UPDATE `table` SET `a`='hello', `b`=1
+```
+
+V klauzuli WHERE lze použít modifikátory `%and` nebo `%or`:
+
+```php
+$result = $database->query('SELECT * FROM users WHERE %and', [
+ 'name' => $name,
+ 'year' => $year,
+]);
+// SELECT * FROM users WHERE `name` = 'Jim' AND `year` = 1978
+```
+
+Viz také [#Složitější dotazy].
+
+Modifikátor `%by` slouží k řazení, v klíčích uvedeme sloupce a hodnotou bude boolean určující, zda řadit vzestupně:
+
+```php
+$result = $database->query('SELECT id FROM author ORDER BY %by', [
+ 'id' => true, // vzestupně
+ 'name' => false, // sestupně
+]);
+// SELECT id FROM author ORDER BY `id`, `name` DESC
+```
+
+
+Insert, Update & Delete
+=======================
+
+Data vkládáme do SQL dotazu jako asociativní pole. Modifikátory ani zástupný znak `?` není nutné v těchto případech uvádět.
+
+```php
+$database->query('INSERT INTO users', [
+ 'name' => $name,
+ 'year' => $year,
+]);
+// INSERT INTO users (`name`, `year`) VALUES ('Jim', 1978)
+
+$id = $database->getInsertId(); // vrátí auto-increment vloženého záznamu
+
+$id = $database->getInsertId($sequence); // nebo hodnotu sekvence
+```
+
+Vícenásobný INSERT:
+
+```php
+$database->query(
+ 'INSERT INTO users',
+ [
+ 'name' => 'Jim',
+ 'year' => 1978,
+ ],
+ [
+ 'name' => 'Jack',
+ 'year' => 1987,
+ ]
+);
+// INSERT INTO users (`name`, `year`) VALUES ('Jim', 1978), ('Jack', 1987)
+```
+
+Mazání:
+
+```php
+$database->query('DELETE FROM users WHERE id = ?', $id);
+
+// vrací počet smazaných řádků
+$affectedRows = $database->getAffectedRows();
+```
+
+Úprava záznamů:
+
+```php
+$database->query('UPDATE users SET', [
+ 'name' => $name,
+ 'year' => $year,
+], 'WHERE id = ?', $id);
+// UPDATE users SET `name` = 'Jim', `year` = 1978 WHERE id = 123
+
+// vrací počet změněných řádků
+$affectedRows = $database->getAffectedRows();
+```
+
+Vložení záznamu, nebo úprava, pokud již existuje:
+
+```php
+$database->query('INSERT INTO users', [
+ 'id' => $id,
+ 'name' => $name,
+ 'year' => $year,
+], 'ON DUPLICATE KEY UPDATE %a', [ // tady už modifikátor %a uvést musíme
+ 'name' => $name,
+ 'year' => $year,
+]);
+// INSERT INTO users (`id`, `name`, `year`) VALUES (123, 'Jim', 1978)
+// ON DUPLICATE KEY UPDATE `name` = 'Jim', `year` = 1978
+```
+
+
+Transakce
+=========
+
+Pro práci s transakcemi slouží čtveřice metod:
+
+```php
+$database->beginTransaction(); // zahájení transakce
+
+$database->commit(); // potvrzení
+
+$database->rollback(); // vrácení zpět
+
+$database->transaction(function () {
+ // nejaka akce
+});
+```
+
+
+Testování
+=========
+
+Abyste si mohli trošku s Dibi hrát, je tu připravena metoda `test()`, které předáte parametry stejně jako `query()`, ovšem místo provedení SQL příkazu se tento barevně vypíše na obrazovku.
+
+Výsledky dotazu je možné vypsat jako tabulku pomocí `$result->dump()`.
+
+K dispozici jsou dále proměnné:
+
+```php
+dibi::$sql; // poslední SQL příklaz
+dibi::$elapsedTime; // jeho doba trvání v sec
+dibi::$numOfQueries; // celkem SQL příkazů
+dibi::$totalTime; // celkový čas v sec
+```
+
+
+Složitější dotazy
+=================
+
+Parametrem může být také objekt `DateTime`.
+
+```php
+$result = $database->query('SELECT * FROM users WHERE created < ?', new DateTime);
+
+$database->query('INSERT INTO users', [
+ 'created' => new DateTime,
+]);
+```
+
+Nebo SQL literál:
+
+```php
+$database->query('UPDATE table SET', [
+ 'date' => $database->literal('NOW()'),
+]);
+// UPDATE table SET `date` = NOW()
+```
+
+Nebo výraz, ve kterém lze používat zástupné znaky `?` nebo modifikátory:
+
+```php
+$database->query('UPDATE `table` SET', [
+ 'title' => $database::expression('SHA1(?)', 'tajne'),
+]);
+// UPDATE `table` SET `title` = SHA1('tajne')
+```
+
+Při update lze modifikátory uvádět přímo v klíčích:
+
+```php
+$database->query('UPDATE table SET', [
+ 'date%SQL' => 'NOW()', // %SQL znamená SQL ;)
+]);
+// UPDATE table SET `date` = NOW()
+```
+
+V podmínkách (tj. u modifikátorů `%and` a `%or`) není nutné uvádět klíče:
+
+```php
+$result = $database->query('SELECT * FROM `table` WHERE %and', [
+ 'number > 10',
+ 'number < 100',
+]);
+// SELECT * FROM `table` WHERE (number > 10) AND (number < 100)
+```
+
+V položkách lze používat i modifikátory nebo zástupné znaky:
+
+```php
+$result = $database->query('SELECT * FROM `table` WHERE %and', [
+ ['number > ?', 10], // nebo $database::expression('number > ?', 10)
+ ['number < ?', 100],
+ ['%or', [
+ 'left' => 1,
+ 'top' => 2,
+ ]],
+]);
+// SELECT * FROM `table` WHERE (number > 10) AND (number < 100) AND (`left` = 1 OR `top` = 2)
+```
+
+Modifikátor `%ex` vloží do SQL všechny prvky pole:
+
+```php
+$result = $database->query('SELECT * FROM `table` WHERE %ex', [
+ $database::expression('left = ?', 1),
+ 'AND',
+ 'top IS NULL',
+]);
+// SELECT * FROM `table` WHERE left = 1 AND top IS NULL
+```
+
+
+Podmínky v SQL příkazu
+======================
+
+Podmíněné SQL příkazy se ovládají pomocí tří modifikátorů `%if`, `%else` a `%end`. První z nich `%if` se musí nacházet zcela na konci řetězce představujícího SQL a za ním následuje proměnná:
+
+```php
+//$user = ???;
+
+$result = $database->query('
+ SELECT *
+ FROM table
+ %if', isset($user), 'WHERE user=%s', $user, '%end
+ ORDER BY name
+');
+```
+
+Podmínku lze doplnit o část `%else`:
+
+```php
+$result = $database->query('
+ SELECT *
+ FROM %if', $cond, 'one_table %else second_table
+');
+```
+
+Podmínky můžete zanořovat do sebe.
+
+
+Identifikátory a řetězce v SQL
+==============================
+
+Samotné SQL prochází zpracováním, aby vyhovovalo konvencím dané databáze. Identifikátory (jména tabulek a sloupců) lze uvozovat do hranatých závorek nebo zpětných uvozovek, dále řetězce jednoduchými či dvojitými uvozovkami, nicméně na server se pošle vždy to, co databáze žádá. Příklad
+
+```php
+$database->query("UPDATE `table` SET [status]='I''m fine'");
+// MySQL: UPDATE `table` SET `status`='I\'m fine'
+// ODBC: UPDATE [table] SET [status]='I''m fine'
+```
+
+Uvozovka se uvnitř řetězce v SQL zapisuje zdvojením.
+
+
+Výsledek jako asociativní pole
+==============================
+
+Příklad: vrátí výsledky jako asociativního pole, kde klíčem bude hodnota políčka `id`:
+
+```php
+$assoc = $result->fetchAssoc('id');
+```
+
+Největší síla funkce `fetchAssoc()` se projeví u SQL dotazu spojujícího několik tabulek s různými typy vazeb. Databáze z toho udělá plochou tabulku, fetchAssoc jí vrátí tvar.
+
+Příklad: Mějme tabulku zákazníků a objednávek (vazba N:M) a položíme dotaz:
+
+```php
+$result = $database->query('
+ SELECT customer_id, customers.name, order_id, orders.number, ...
+ FROM customers
+ INNER JOIN orders USING (customer_id)
+ WHERE ...
+');
+```
+
+A rádi bychom získali vnořené asociativní pole podle ID zákazníka a poté podle ID objednávky:
+
+```php
+$all = $result->fetchAssoc('customer_id|order_id');
+
+// budeme jej procházet takto:
+foreach ($all as $customerId => $orders) {
+ foreach ($orders as $orderId => $order) {
+ // ...
+ }
+}
+```
+
+Asociativní deskriptor má obdobnou syntax, jako když pole píšete pomocí přiřazení v PHP. Tedy `'customer_id|order_id'` představuje sérii přiřazení `$all[$customerId][$orderId] = $row;`, postupně pro všechny řádky.
+
+Někdy by se hodilo, aby se asociovalo podle jména zákazníka namísto jeho ID:
+
+```php
+$all = $result->fetchAssoc('name|order_id');
+
+// k prvkům pak přistupujeme třeba takto:
+$order = $all['Arnold Rimmer'][$orderId];
+```
+
+Co když ale existuje více zákazníků se stejným jménem? Tabulka by měla mít spíš tvar:
+
+```php
+$row = $all['Arnold Rimmer'][0][$orderId];
+$row = $all['Arnold Rimmer'][1][$orderId];
+```
+
+Rozlišujeme tedy více možných Rimmerů pomocí klasického pole. Asociativní deskriptor má opět formát podobný přiřazování, s tím, že sekvenční pole představuje `[]`:
+
+```php
+$all = $result->fetchAssoc('name[]order_id');
+
+// iterujeme všechny Arnoldy ve výsledcích
+foreach ($all['Arnold Rimmer'] as $arnoldOrders) {
+ foreach ($arnoldOrders as $orderId => $order) {
+ // ...
+ }
+}
+```
+
+Vrátíme se k příkladu s deskriptorem `'customer_id|order_id'` a zkusíme vypsat objednávky jednotlivých zákazníků:
+
+```php
+$all = $result->fetchAssoc('customer_id|order_id');
+
+foreach ($all as $customerId => $orders) {
+ echo "Objednávky zákazníka $customerId:";
+
+ foreach ($orders as $orderId => $order) {
+ echo "Číslo dokladu: $order->number";
+ // jméno zákazníka je v $order->name
+ }
+}
+```
+
+Bylo by hezké místo ID zákazníka vypsat jeho jméno. Jenže to bychom museli dohledávat v poli `$orders`. Výsledky si proto necháme upravit do takovéhoto tvaru:
+
+```php
+$all[$customerId]->name = 'John Doe';
+$all[$customerId]->order_id[$orderId] = $row;
+$all[$customerId]->order_id[$orderId2] = $row2;
+```
+
+Tedy mezi `$customerId` a `$orderId` vložíme ještě mezičlánek. Tentokrát ne číslované indexy, jaké jsme použili pro odlišení jednotlivých Rimmerů, ale rovnou databázový záznam. Řešení je velmi podobné, jen si stačí zapamatovat, že záznam symbolizuje šipka:
+
+```php
+$all = $result->fetchAssoc('customer_id->order_id');
+
+foreach ($all as $customerId => $row) {
+ echo "Objednávky zákazníka $row->name:";
+
+ foreach ($row->order_id as $orderId => $order) {
+ echo "Číslo dokladu: $order->number";
+ }
+}
+```
+
+
+Prefixy & substituce
+====================
+
+Názvy tabulek a sloupců mohou obsahovat proměnné části. Ty si nejprve nadefinujeme:
+
+```php
+// vytvoří novou substituci :blog: ==> wp_
+$database->substitute('blog', 'wp_');
+```
+
+a poté použijeme v SQL. Všimněte si, že v SQL jsou uvozeny dvojtečkama:
+
+```php
+$database->query("UPDATE [:blog:items] SET [text]='Hello World'");
+// UPDATE `wp_items` SET `text`='Hello World'
+```
+
+
+Datové typy buňek
+=================
+
+Dibi automaticky detekuje typy jednotlivých sloupců dotazu a převádí buňky na nativní typy PHP. Typ můžeme určit i manuálně. Možné typy najdete ve třídě [Dibi\Type |api:Dibi\Type].
+
+```php
+$result->setType('id', Dibi\Type::INTEGER); // id bude integer
+$row = $result->fetch();
+
+is_int($row->id) // true
+```
+
+
+Logování
+========
+
+Dibi má v sobě zabudovaný logger, kterým můžete sledovat všechny vykonané SQL příkazy a měřit délku jejich trvání. Aktivace:
+
+```php
+$database->connect([
+ 'driver' => 'sqlite',
+ 'database' => 'sample.sdb',
+ 'profiler' => [
+ 'file' => 'file.log',
+ ],
+]);
+```
+
+Šikovnější profiler je panel pro Tracy, který se aktivuje při propojení s Nette.
+
+
+Připojení do [Nette |https://nette.org]
+=======================================
+
+V konfiguračním souboru zaregistrujeme DI rozšíření a přidáme sekci `dibi` - tím se vytvoří potřebné objekty a také databázový panel v [Tracy |https://tracy.nette.org] debugger baru.
+
+```neon
+extensions:
+ dibi: Dibi\Bridges\Nette\DibiExtension22
+
+dibi:
+ host: localhost
+ username: root
+ password: ***
+ database: foo
+ lazy: true
+```
+
+Poté objekt spojení [získáme jako službu z DI kontejneru |https://doc.nette.org/di-usage], např.:
+
+```php
+class Model
+{
+ private $database;
+
+ public function __construct(Dibi\Connection $database)
+ {
+ $this->database = $database;
+ }
+}
+```
+
+
+Komunitní rozšíření
+===================
+
+Nad Dibi staví nejrůznější knihovny, ORM a rozšíření. Celý jejich seznam najdete na "Packagistu":https://packagist.org/packages/dibi/dibi/dependents?order_by=downloads&requires=require.
+
+
+{{maintitle: Dibi – Šikovná Database Abstraction Library pro PHP}}
diff --git a/dibi/cs/@menu.texy b/dibi/cs/@menu.texy
new file mode 100644
index 0000000000..271662aad7
--- /dev/null
+++ b/dibi/cs/@menu.texy
@@ -0,0 +1,4 @@
+- [Úvod | @home]
+- "Blog .[link-external]":https://phpfashion.com/category/dibi
+- "API .[link-external]":https://api.nette.org/dibi/
+- "GitHub .[link-external]":https://github.com/dg/dibi
diff --git a/dibi/cs/@meta.texy b/dibi/cs/@meta.texy
new file mode 100644
index 0000000000..49d44d0cfa
--- /dev/null
+++ b/dibi/cs/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Dibi Dokumentace}}
diff --git a/dibi/en/@home.texy b/dibi/en/@home.texy
new file mode 100644
index 0000000000..a227c5627e
--- /dev/null
+++ b/dibi/en/@home.texy
@@ -0,0 +1,656 @@
+Dibi: Smart Database Abstraction Library for PHP
+************************************************
+
+To install the latest stable Dibi version, use the [Composer|best-practices:composer] command:
+
+```
+composer require dibi/dibi
+```
+
+You can find version overview on the [Releases | https://github.com/dg/dibi/releases] page.
+
+Requires PHP 8.0 or newer.
+
+
+Connecting to Database
+======================
+
+The database connection is represented by the [Dibi\Connection|api:] object:
+
+```php
+$database = new Dibi\Connection([
+ 'driver' => 'mysqli',
+ 'host' => 'localhost',
+ 'username' => 'root',
+ 'password' => '***',
+ 'database' => 'table',
+]);
+
+$result = $database->query('SELECT * FROM users');
+```
+
+Alternatively, you can use the `dibi` static registry, which maintains a connection object in globally accessible storage and calls all functions on it:
+
+```php
+dibi::connect([
+ 'driver' => 'mysqli',
+ 'host' => 'localhost',
+ 'username' => 'root',
+ 'password' => '***',
+ 'database' => 'test',
+ 'charset' => 'utf8',
+]);
+
+$result = dibi::query('SELECT * FROM users');
+```
+
+In case of a connection error, it throws `Dibi\Exception`.
+
+
+Queries
+=======
+
+We query the database using the `query()` method, which returns [Dibi\Result |api:Dibi\Result]. Rows are returned as [Dibi\Row |api:Dibi\Row] objects.
+
+You can try all the examples [online at the playground |https://repl.it/@DavidGrudl/dibi-playground].
+
+```php
+$result = $database->query('SELECT * FROM users');
+
+foreach ($result as $row) {
+ echo $row->id;
+ echo $row->name;
+}
+
+// array of all rows
+$all = $result->fetchAll();
+
+// array of all rows, keyed by 'id'
+$all = $result->fetchAssoc('id');
+
+// associative pairs id => name
+$pairs = $result->fetchPairs('id', 'name');
+
+// number of result rows, if known, or number of affected rows
+$count = $result->getRowCount();
+```
+
+The fetchAssoc() method can return [more complex associative arrays |#Result as associative array].
+
+You can easily add parameters to the query - note the question mark:
+
+```php
+$result = $database->query('SELECT * FROM users WHERE name = ? AND active = ?', $name, $active);
+
+// or
+$result = $database->query('SELECT * FROM users WHERE name = ?', $name, 'AND active = ?', $active);
+
+$ids = [10, 20, 30];
+$result = $database->query('SELECT * FROM users WHERE id IN (?)', $ids);
+```
+
+
+**WARNING: never concatenate parameters into SQL queries, as this would create [SQL injection |https://en.wikipedia.org/wiki/SQL_injection] vulnerability**
+/--
+$database->query('SELECT * FROM users WHERE id = ' . $id); // BAD!!!
+\--
+
+
+Instead of question marks, you can also use so-called [#modifiers].
+
+```php
+$result = $database->query('SELECT * FROM users WHERE name = %s', $name);
+```
+
+In case of failure, `query()` throws either `Dibi\Exception` or one of its descendants:
+
+- [ConstraintViolationException |api:Dibi\ConstraintViolationException] - violation of some table constraint
+- [ForeignKeyConstraintViolationException |api:Dibi\ForeignKeyConstraintViolationException] - invalid foreign key
+- [NotNullConstraintViolationException |api:Dibi\NotNullConstraintViolationException] - violation of the NOT NULL condition
+- [UniqueConstraintViolationException |api:Dibi\UniqueConstraintViolationException] - collision with unique index
+
+You can also use shortcut methods:
+
+```php
+// returns associative pairs id => name, shortcut for query(...)->fetchPairs()
+$pairs = $database->fetchPairs('SELECT id, name FROM users');
+
+// returns array of all rows, shortcut for query(...)->fetchAll()
+$rows = $database->fetchAll('SELECT * FROM users');
+
+// returns row, shortcut for query(...)->fetch()
+$row = $database->fetch('SELECT * FROM users WHERE id = ?', $id);
+
+// returns cell, shortcut for query(...)->fetchSingle()
+$name = $database->fetchSingle('SELECT name FROM users WHERE id = ?', $id);
+```
+
+
+Modifiers
+=========
+
+In addition to the `?` placeholder, we can also use modifiers:
+
+| %s | string
+| %sN | string, but '' translates as NULL
+| %bin | binary data
+| %b | boolean
+| %i | integer
+| %iN | integer, but 0 translates as NULL
+| %f | float
+| %d | date (accepts DateTime, string or UNIX timestamp)
+| %dt | datetime (accepts DateTime, string or UNIX timestamp)
+| %n | identifier, i.e. table or column name
+| %N | identifier, treats period as ordinary character
+| %SQL | SQL - directly inserts into SQL (alternative is Dibi\Literal)
+| %ex | expands array
+| %lmt | special - adds LIMIT to the query
+| %ofs | special - adds OFFSET to the query
+
+Example:
+
+```php
+$result = $database->query('SELECT * FROM users WHERE name = %s', $name);
+```
+
+If `$name` is `null`, `NULL` is inserted into the SQL statement.
+
+If the variable is an array, the modifier is applied to all of its elements and they are inserted into SQL separated by commas:
+
+```php
+$ids = [10, '20', 30];
+$result = $database->query('SELECT * FROM users WHERE id IN (%i)', $ids);
+// SELECT * FROM users WHERE id IN (10, 20, 30)
+```
+
+The `%n` modifier is used when the table or column name is a variable. (Beware: do not allow the user to manipulate the content of such a variable):
+
+```php
+$table = 'blog.users';
+$column = 'name';
+$result = $database->query('SELECT * FROM %n WHERE %n = ?', $table, $column, $value);
+// SELECT * FROM `blog`.`users` WHERE `name` = 'Jim'
+```
+
+Four special modifiers are available for the LIKE operator:
+
+| %like~ | expression starts with string
+| %~like | expression ends with string
+| %~like~ | expression contains string
+| `%like` | expression matches string
+
+Search for names starting with a certain string:
+
+```php
+$result = $database->query('SELECT * FROM table WHERE name LIKE %like~', $query);
+```
+
+
+Array Modifiers
+===============
+
+The parameter inserted into an SQL query can also be an array. These modifiers determine how to construct the SQL statement from it:
+
+| %and | | `key1 = value1 AND key2 = value2 AND ...`
+| %or | | `key1 = value1 OR key2 = value2 OR ...`
+| %a | assoc | `key1 = value1, key2 = value2, ...`
+| %l %in | list | `(val1, val2, ...)`
+| %v | values | `(key1, key2, ...) VALUES (value1, value2, ...)`
+| %m | multi | `(key1, key2, ...) VALUES (value1, value2, ...), (value1, value2, ...), ...`
+| %by | ordering | `key1 ASC, key2 DESC ...`
+| %n | names | `key1, key2 AS alias, ...`
+
+Example:
+
+```php
+$arr = [
+ 'a' => 'hello',
+ 'b' => true,
+];
+
+$database->query('INSERT INTO table %v', $arr);
+// INSERT INTO `table` (`a`, `b`) VALUES ('hello', 1)
+
+$database->query('UPDATE `table` SET %a', $arr);
+// UPDATE `table` SET `a`='hello', `b`=1
+```
+
+In the WHERE clause, you can use `%and` or `%or` modifiers:
+
+```php
+$result = $database->query('SELECT * FROM users WHERE %and', [
+ 'name' => $name,
+ 'year' => $year,
+]);
+// SELECT * FROM users WHERE `name` = 'Jim' AND `year` = 1978
+```
+
+See also [#Complex queries].
+
+The `%by` modifier is used for sorting - keys specify the columns, and the boolean value determines whether to sort in ascending order:
+
+```php
+$result = $database->query('SELECT id FROM author ORDER BY %by', [
+ 'id' => true, // ascending
+ 'name' => false, // descending
+]);
+// SELECT id FROM author ORDER BY `id`, `name` DESC
+```
+
+
+Insert, Update & Delete
+=======================
+
+We insert data into SQL queries as associative arrays. Modifiers and the `?` placeholder are not necessary in these cases.
+
+```php
+$database->query('INSERT INTO users', [
+ 'name' => $name,
+ 'year' => $year,
+]);
+// INSERT INTO users (`name`, `year`) VALUES ('Jim', 1978)
+
+$id = $database->getInsertId(); // returns the auto-increment of the inserted record
+
+$id = $database->getInsertId($sequence); // or sequence value
+```
+
+Multiple INSERT:
+
+```php
+$database->query(
+ 'INSERT INTO users',
+ [
+ 'name' => 'Jim',
+ 'year' => 1978,
+ ],
+ [
+ 'name' => 'Jack',
+ 'year' => 1987,
+ ]
+);
+// INSERT INTO users (`name`, `year`) VALUES ('Jim', 1978), ('Jack', 1987)
+```
+
+Deleting:
+
+```php
+$database->query('DELETE FROM users WHERE id = ?', $id);
+
+// returns number of deleted rows
+$affectedRows = $database->getAffectedRows();
+```
+
+Updating records:
+
+```php
+$database->query('UPDATE users SET', [
+ 'name' => $name,
+ 'year' => $year,
+], 'WHERE id = ?', $id);
+// UPDATE users SET `name` = 'Jim', `year` = 1978 WHERE id = 123
+
+// returns the number of updated rows
+$affectedRows = $database->getAffectedRows();
+```
+
+Substitute any identifier:
+
+```php
+$database->query('INSERT INTO users', [
+ 'id' => $id,
+ 'name' => $name,
+ 'year' => $year,
+], 'ON DUPLICATE KEY UPDATE %a', [ // here the modifier %a must be used
+ 'name' => $name,
+ 'year' => $year,
+]);
+// INSERT INTO users (`id`, `name`, `year`) VALUES (123, 'Jim', 1978)
+// ON DUPLICATE KEY UPDATE `name` = 'Jim', `year` = 1978
+```
+
+
+Transaction
+===========
+
+There are four methods for dealing with transactions:
+
+```php
+$database->beginTransaction();
+
+$database->commit();
+
+$database->rollback();
+
+$database->transaction(function () {
+ // some action
+});
+```
+
+
+Testing
+=======
+
+In order to play with Dibi a little, there is a `test()` method that you pass parameters like to `query()`, but instead of executing the SQL statement, it is echoed on the screen.
+
+The query results can be echoed as a table using `$result->dump()`.
+
+These variables are also available:
+
+```php
+dibi::$sql; // the latest SQL query
+dibi::$elapsedTime; // its duration in sec
+dibi::$numOfQueries;
+dibi::$totalTime;
+```
+
+
+Complex Queries
+===============
+
+The parameter may also be an object `DateTime`.
+
+```php
+$result = $database->query('SELECT * FROM users WHERE created < ?', new DateTime);
+
+$database->query('INSERT INTO users', [
+ 'created' => new DateTime,
+]);
+```
+
+Or SQL literal:
+
+```php
+$database->query('UPDATE table SET', [
+ 'date' => $database->literal('NOW()'),
+]);
+// UPDATE table SET `date` = NOW()
+```
+
+Or an expression in which you can use `?` or modifiers:
+
+```php
+$database->query('UPDATE `table` SET', [
+ 'title' => $database::expression('SHA1(?)', 'secret'),
+]);
+// UPDATE `table` SET `title` = SHA1('secret')
+```
+
+When updating, modifiers can be placed directly in the keys:
+
+```php
+$database->query('UPDATE table SET', [
+ 'date%SQL' => 'NOW()', // %SQL means SQL ;)
+]);
+// UPDATE table SET `date` = NOW()
+```
+
+In conditions (ie, for `%and` and `%or` modifiers), it is not necessary to specify the keys:
+
+```php
+$result = $database->query('SELECT * FROM `table` WHERE %and', [
+ 'number > 10',
+ 'number < 100',
+]);
+// SELECT * FROM `table` WHERE (number > 10) AND (number < 100)
+```
+
+Modifiers or placeholders can also be used in expressions:
+
+```php
+$result = $database->query('SELECT * FROM `table` WHERE %and', [
+ ['number > ?', 10], // or $database::expression('number > ?', 10)
+ ['number < ?', 100],
+ ['%or', [
+ 'left' => 1,
+ 'top' => 2,
+ ]],
+]);
+// SELECT * FROM `table` WHERE (number > 10) AND (number < 100) AND (`left` = 1 OR `top` = 2)
+```
+
+The `%ex` modifier inserts all items of the array into SQL:
+
+```php
+$result = $database->query('SELECT * FROM `table` WHERE %ex', [
+ $database::expression('left = ?', 1),
+ 'AND',
+ 'top IS NULL',
+]);
+// SELECT * FROM `table` WHERE left = 1 AND top IS NULL
+```
+
+
+Conditions in SQL Statements
+============================
+
+Conditional SQL statements are controlled by three modifiers: `%if`, `%else`, and `%end`. The `%if` must be at the end of the string representing SQL and is followed by a variable:
+
+```php
+//$user = ???;
+
+$result = $database->query('
+ SELECT *
+ FROM table
+ %if', isset($user), 'WHERE user=%s', $user, '%end
+ ORDER BY name
+');
+```
+
+The condition can be supplemented with an `%else` section:
+
+```php
+$result = $database->query('
+ SELECT *
+ FROM %if', $cond, 'one_table %else second_table
+');
+```
+
+Conditions can be nested within each other.
+
+
+Identifiers and Strings in SQL
+==============================
+
+SQL itself goes through processing to meet the conventions of the given database. Identifiers (table and column names) can be enclosed in square brackets or backticks, and strings in single or double quotes, but the server always sends what the database requires. Example:
+
+```php
+$database->query("UPDATE `table` SET [status]='I''m fine'");
+// MySQL: UPDATE `table` SET `status`='I\'m fine'
+// ODBC: UPDATE [table] SET [status]='I''m fine'
+```
+
+Quotes inside strings in SQL are written by doubling them.
+
+
+Result as Associative Array
+===========================
+
+Example: returns results as an associative array where the key will be the value of the `id` field:
+
+```php
+$assoc = $result->fetchAssoc('id');
+```
+
+The greatest power of `fetchAssoc()` is demonstrated in SQL queries joining several tables with different types of relationships. The database creates a flat table, fetchAssoc restores the shape.
+
+Example: Let's have a customer and order table (N:M relationship) and query:
+
+```php
+$result = $database->query('
+ SELECT customer_id, customers.name, order_id, orders.number, ...
+ FROM customers
+ INNER JOIN orders USING (customer_id)
+ WHERE ...
+');
+```
+
+And we'd like to get a nested associative array by Customer ID and then by Order ID:
+
+```php
+$all = $result->fetchAssoc('customer_id|order_id');
+
+// we will iterate like this:
+foreach ($all as $customerId => $orders) {
+ foreach ($orders as $orderId => $order) {
+ // ...
+ }
+}
+```
+
+The associative descriptor has similar syntax to when you write arrays using assignment in PHP. Thus `'customer_id|order_id'` represents the assignment series `$all[$customerId][$orderId] = $row;` sequentially for all rows.
+
+Sometimes it would be useful to associate by the customer's name instead of their ID:
+
+```php
+$all = $result->fetchAssoc('name|order_id');
+
+// elements are then accessed like this:
+$order = $all['Arnold Rimmer'][$orderId];
+```
+
+But what if there are multiple customers with the same name? The table should have the form:
+
+```php
+$row = $all['Arnold Rimmer'][0][$orderId];
+$row = $all['Arnold Rimmer'][1][$orderId];
+```
+
+So we distinguish multiple possible Rimmers using a regular array. The associative descriptor again has a format similar to assignment, with sequential arrays represented by `[]`:
+
+```php
+$all = $result->fetchAssoc('name[]order_id');
+
+// we iterate all Arnolds in the results
+foreach ($all['Arnold Rimmer'] as $arnoldOrders) {
+ foreach ($arnoldOrders as $orderId => $order) {
+ // ...
+ }
+}
+```
+
+Returning to the example with the `customer_id|order_id` descriptor, let's try to list orders for each customer:
+
+```php
+$all = $result->fetchAssoc('customer_id|order_id');
+
+foreach ($all as $customerId => $orders) {
+ echo "Orders for customer $customerId:";
+
+ foreach ($orders as $orderId => $order) {
+ echo "Document number: $order->number";
+ // customer name is in $order->name
+ }
+}
+```
+
+It would be nice to display the customer name instead of ID. But we would have to look it up in the `$orders` array. So let's modify the results to have this shape:
+
+```php
+$all[$customerId]->name = 'John Doe';
+$all[$customerId]->order_id[$orderId] = $row;
+$all[$customerId]->order_id[$orderId2] = $row2;
+```
+
+So, between `$customerId` and `$orderId`, we insert an intermediate element. This time not numbered indexes as we used to distinguish individual Rimmers, but directly a database record. The solution is very similar - just remember that a record is symbolized by an arrow:
+
+```php
+$all = $result->fetchAssoc('customer_id->order_id');
+
+foreach ($all as $customerId => $row) {
+ echo "Orders for customer $row->name:";
+
+ foreach ($row->order_id as $orderId => $order) {
+ echo "Document number: $order->number";
+ }
+}
+```
+
+
+Prefixes & Substitutions
+========================
+
+Table and column names can contain variable parts. You will first define them:
+
+```php
+// create new substitution :blog: ==> wp_
+$database->substitute('blog', 'wp_');
+```
+
+and then use them in SQL. Note that in SQL they are enclosed in colons:
+
+```php
+$database->query("UPDATE [:blog:items] SET [text]='Hello World'");
+// UPDATE `wp_items` SET `text`='Hello World'
+```
+
+
+Field Data Types
+================
+
+Dibi automatically detects the types of individual query columns and converts cells to native PHP types. We can also specify the type manually. Possible types can be found in the [Dibi\Type |api:Dibi\Type] class.
+
+```php
+$result->setType('id', Dibi\Type::INTEGER); // id will be integer
+$row = $result->fetch();
+
+is_int($row->id) // true
+```
+
+
+Logging
+=======
+
+Dibi has a built-in logger that lets you track all executed SQL statements and measure the duration of their execution. Activation:
+
+```php
+$database->connect([
+ 'driver' => 'sqlite',
+ 'database' => 'sample.sdb',
+ 'profiler' => [
+ 'file' => 'file.log',
+ ],
+]);
+```
+
+A more versatile profiler is the Tracy panel, which is activated when connecting to Nette.
+
+
+Connect to [Nette |https://nette.org]
+=====================================
+
+In the configuration file, we register the DI extension and add the `dibi` section - this creates the required objects and also the database panel in the [Tracy |https://tracy.nette.org] debugger bar.
+
+```neon
+extensions:
+ dibi: Dibi\Bridges\Nette\DibiExtension22
+
+dibi:
+ host: localhost
+ username: root
+ password: ***
+ database: foo
+ lazy: true
+```
+
+Then the connection object can be [obtained as a service from the DI container |https://doc.nette.org/di-usage], e.g.:
+
+```php
+class Model
+{
+ private $database;
+
+ public function __construct(Dibi\Connection $database)
+ {
+ $this->database = $database;
+ }
+}
+```
+
+
+Community Extensions
+====================
+
+Various libraries, ORMs and extensions are built on top of Dibi. You can find a complete list of them on "Packagist":https://packagist.org/packages/dibi/dibi/dependents?order_by=downloads&requires=require.
+
+{{maintitle: Dibi – Smart Database Abstraction Library for PHP}}
diff --git a/dibi/en/@menu.texy b/dibi/en/@menu.texy
new file mode 100644
index 0000000000..4add6468f0
--- /dev/null
+++ b/dibi/en/@menu.texy
@@ -0,0 +1,3 @@
+- [Home | @home]
+- "API .[link-external]":https://api.nette.org/dibi/
+- "GitHub .[link-external]":https://github.com/dg/dibi
diff --git a/dibi/en/@meta.texy b/dibi/en/@meta.texy
new file mode 100644
index 0000000000..b9ca163d2f
--- /dev/null
+++ b/dibi/en/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Dibi Documentation}}
diff --git a/dibi/meta.json b/dibi/meta.json
new file mode 100644
index 0000000000..ef3653f6bc
--- /dev/null
+++ b/dibi/meta.json
@@ -0,0 +1,5 @@
+{
+ "version": "5.x",
+ "repo": "dg/dibi",
+ "composer": "dibi/dibi"
+}
diff --git a/forms/bg/@meta.texy b/forms/bg/@meta.texy
new file mode 100644
index 0000000000..57804a1127
--- /dev/null
+++ b/forms/bg/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация на Nette}}
diff --git a/forms/cs/@meta.texy b/forms/cs/@meta.texy
new file mode 100644
index 0000000000..462d9add80
--- /dev/null
+++ b/forms/cs/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentace}}
diff --git a/forms/cs/controls.texy b/forms/cs/controls.texy
index c8262c9a9d..8b3396fa72 100644
--- a/forms/cs/controls.texy
+++ b/forms/cs/controls.texy
@@ -441,7 +441,7 @@ U všech prvků můžeme volat následující metody (kompletní přehled v [API
.[table-form-methods language-php]
| `setDefaultValue($value)` | nastaví výchozí hodnotu
-| `getValue()` | získat aktuální hodnotu
+| `getValue()` | získá aktuální hodnotu
| `setOmitted()` | [#vynechání hodnoty]
| `setDisabled()` | [#deaktivace prvků]
diff --git a/forms/cs/in-presenter.texy b/forms/cs/in-presenter.texy
index 33ac7fa95d..2c827d31f7 100644
--- a/forms/cs/in-presenter.texy
+++ b/forms/cs/in-presenter.texy
@@ -19,7 +19,7 @@ $form = new Form;
$form->addText('name', 'Jméno:');
$form->addPassword('password', 'Heslo:');
$form->addSubmit('send', 'Registrovat');
-$form->onSuccess[] = [$this, 'formSucceeded'];
+$form->onSuccess[] = $this->formSucceeded(...);
```
a v prohlížeči se zobrazí takto:
@@ -42,11 +42,11 @@ class HomePresenter extends Nette\Application\UI\Presenter
$form->addText('name', 'Jméno:');
$form->addPassword('password', 'Heslo:');
$form->addSubmit('send', 'Registrovat');
- $form->onSuccess[] = [$this, 'formSucceeded'];
+ $form->onSuccess[] = $this->formSucceeded(...);
return $form;
}
- public function formSucceeded(Form $form, $data): void
+ private function formSucceeded(Form $form, $data): void
{
// tady zpracujeme data odeslaná formulářem
// $data->name obsahuje jméno
@@ -303,16 +303,16 @@ Pokud má formulář více než jedno tlačítko, potřebujeme zpravidla rozliš
```php
$form->addSubmit('save', 'Uložit')
- ->onClick[] = [$this, 'saveButtonPressed'];
+ ->onClick[] = $this->saveButtonPressed(...);
$form->addSubmit('delete', 'Smazat')
- ->onClick[] = [$this, 'deleteButtonPressed'];
+ ->onClick[] = $this->deleteButtonPressed(...);
```
Tyto handlery se volají pouze v případě validně vyplněného formuláře, stejně jako v případě události `onSuccess`. Rozdíl je v tom, že jako první parametr se místo formulář může předat odesílací tlačítko, záleží na typu, který uvedete:
```php
-public function saveButtonPressed(Nette\Forms\Controls\Button $button, $data)
+private function saveButtonPressed(Nette\Forms\Controls\Button $button, $data)
{
$form = $button->getForm();
// ...
@@ -403,7 +403,7 @@ protected function createComponentSignInForm(): Form
$form = $this->formFactory->create();
// můžeme formulář pozměnit, zde například měníme popisku na tlačítku
$form['send']->setCaption('Pokračovat');
- $form->onSuccess[] = [$this, 'signInFormSuceeded']; // a přidáme handler
+ $form->onSuccess[] = $this->signInFormSuceeded(...); // a přidáme handler
return $form;
}
```
diff --git a/forms/cs/validation.texy b/forms/cs/validation.texy
index e313be57b9..479e12df74 100644
--- a/forms/cs/validation.texy
+++ b/forms/cs/validation.texy
@@ -223,11 +223,11 @@ protected function createComponentSignInForm(): Form
{
$form = new Form;
// ...
- $form->onValidate[] = [$this, 'validateSignInForm'];
+ $form->onValidate[] = $this->validateSignInForm(...);
return $form;
}
-public function validateSignInForm(Form $form, \stdClass $data): void
+private function validateSignInForm(Form $form, \stdClass $data): void
{
if ($data->foo > 1 && $data->bar > 5) {
$form->addError('Tato kombinace není možná.');
diff --git a/forms/de/@meta.texy b/forms/de/@meta.texy
new file mode 100644
index 0000000000..b3b806b2ca
--- /dev/null
+++ b/forms/de/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentation}}
diff --git a/forms/el/@meta.texy b/forms/el/@meta.texy
new file mode 100644
index 0000000000..88e29852c7
--- /dev/null
+++ b/forms/el/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Τεκμηρίωση}}
diff --git a/forms/en/@meta.texy b/forms/en/@meta.texy
new file mode 100644
index 0000000000..42471908b0
--- /dev/null
+++ b/forms/en/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentation}}
diff --git a/forms/en/in-presenter.texy b/forms/en/in-presenter.texy
index a1543bcaa1..b4cde43641 100644
--- a/forms/en/in-presenter.texy
+++ b/forms/en/in-presenter.texy
@@ -19,14 +19,14 @@ $form = new Form;
$form->addText('name', 'Name:');
$form->addPassword('password', 'Password:');
$form->addSubmit('send', 'Sign up');
-$form->onSuccess[] = [$this, 'formSucceeded'];
+$form->onSuccess[] = $this->formSucceeded(...);
```
and in the browser, it will be displayed like this:
[* form-en.webp *]
-A form in a presenter is an object of the `Nette\Application\UI\Form` class; its predecessor `Nette\Forms\Form` is intended for standalone use. We added controls named name, password, and a submit button. Finally, the line `$form->onSuccess[] = [$this, 'formSucceeded'];` states that after submission and successful validation, the method `$this->formSucceeded()` should be called.
+A form in a presenter is an object of the `Nette\Application\UI\Form` class; its predecessor `Nette\Forms\Form` is intended for standalone use. We added controls named name, password, and a submit button. Finally, the line `$form->onSuccess` states that after submission and successful validation, the method `$this->formSucceeded()` should be called.
From the presenter's perspective, the form is a regular component. Therefore, it is treated as a component and integrated into the presenter using a [factory method |application:components#Factory Methods]. It will look like this:
@@ -42,11 +42,11 @@ class HomePresenter extends Nette\Application\UI\Presenter
$form->addText('name', 'Name:');
$form->addPassword('password', 'Password:');
$form->addSubmit('send', 'Sign up');
- $form->onSuccess[] = [$this, 'formSucceeded'];
+ $form->onSuccess[] = $this->formSucceeded(...);
return $form;
}
- public function formSucceeded(Form $form, $data): void
+ private function formSucceeded(Form $form, $data): void
{
// here we will process the data sent by the form
// $data->name contains name
@@ -303,16 +303,16 @@ If the form has more than one button, we usually need to distinguish which one w
```php
$form->addSubmit('save', 'Save')
- ->onClick[] = [$this, 'saveButtonPressed'];
+ ->onClick[] = $this->saveButtonPressed(...);
$form->addSubmit('delete', 'Delete')
- ->onClick[] = [$this, 'deleteButtonPressed'];
+ ->onClick[] = $this->deleteButtonPressed(...);
```
These handlers are called only if the form is validly filled (unless validation is disabled for the button), just like the `onSuccess` event. The difference is that the first parameter passed can be the submit button object instead of the form, depending on the type hint you specify:
```php
-public function saveButtonPressed(Nette\Forms\Controls\Button $button, $data)
+private function saveButtonPressed(Nette\Forms\Controls\Button $button, $data)
{
$form = $button->getForm();
// ...
@@ -403,7 +403,7 @@ protected function createComponentSignInForm(): Form
$form = $this->formFactory->create();
// we can change the form, here for example we change the label on the button
$form['login']->setCaption('Continue');
- $form->onSuccess[] = [$this, 'signInFormSubmitted']; // and add handler
+ $form->onSuccess[] = $this->signInFormSubmitted(...); // and add handler
return $form;
}
```
diff --git a/forms/en/validation.texy b/forms/en/validation.texy
index 0c32b3bb85..d9a9626cc6 100644
--- a/forms/en/validation.texy
+++ b/forms/en/validation.texy
@@ -223,11 +223,11 @@ protected function createComponentSignInForm(): Form
{
$form = new Form;
// ...
- $form->onValidate[] = [$this, 'validateSignInForm'];
+ $form->onValidate[] = $this->validateSignInForm(...);
return $form;
}
-public function validateSignInForm(Form $form, \stdClass $data): void
+private function validateSignInForm(Form $form, \stdClass $data): void
{
if ($data->foo > 1 && $data->bar > 5) {
$form->addError('This combination is not possible.');
diff --git a/forms/es/@meta.texy b/forms/es/@meta.texy
new file mode 100644
index 0000000000..1670b124ad
--- /dev/null
+++ b/forms/es/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentación}}
diff --git a/forms/fr/@meta.texy b/forms/fr/@meta.texy
new file mode 100644
index 0000000000..72ae4b8db8
--- /dev/null
+++ b/forms/fr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentation Nette}}
diff --git a/forms/hu/@meta.texy b/forms/hu/@meta.texy
new file mode 100644
index 0000000000..c172d1cda5
--- /dev/null
+++ b/forms/hu/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette dokumentáció}}
diff --git a/forms/it/@meta.texy b/forms/it/@meta.texy
new file mode 100644
index 0000000000..4647d0c8a2
--- /dev/null
+++ b/forms/it/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentazione Nette}}
diff --git a/forms/ja/@meta.texy b/forms/ja/@meta.texy
new file mode 100644
index 0000000000..d3c41dc3d7
--- /dev/null
+++ b/forms/ja/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette ドキュメンテーション}}
diff --git a/forms/pl/@meta.texy b/forms/pl/@meta.texy
new file mode 100644
index 0000000000..61ac92d1af
--- /dev/null
+++ b/forms/pl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Dokumentacja Nette}}
diff --git a/forms/pt/@meta.texy b/forms/pt/@meta.texy
new file mode 100644
index 0000000000..41a853b6aa
--- /dev/null
+++ b/forms/pt/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentação Nette}}
diff --git a/forms/ro/@meta.texy b/forms/ro/@meta.texy
new file mode 100644
index 0000000000..9c744b37d6
--- /dev/null
+++ b/forms/ro/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentație Nette}}
diff --git a/forms/ru/@meta.texy b/forms/ru/@meta.texy
new file mode 100644
index 0000000000..7f329adfce
--- /dev/null
+++ b/forms/ru/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация Nette}}
diff --git a/forms/sl/@meta.texy b/forms/sl/@meta.texy
new file mode 100644
index 0000000000..724324bee5
--- /dev/null
+++ b/forms/sl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentacija}}
diff --git a/forms/tr/@meta.texy b/forms/tr/@meta.texy
new file mode 100644
index 0000000000..8dfe82f311
--- /dev/null
+++ b/forms/tr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokümantasyonu}}
diff --git a/forms/uk/@meta.texy b/forms/uk/@meta.texy
new file mode 100644
index 0000000000..96e2d9752a
--- /dev/null
+++ b/forms/uk/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документація Nette}}
diff --git a/http/bg/@meta.texy b/http/bg/@meta.texy
new file mode 100644
index 0000000000..57804a1127
--- /dev/null
+++ b/http/bg/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация на Nette}}
diff --git a/http/cs/@meta.texy b/http/cs/@meta.texy
new file mode 100644
index 0000000000..462d9add80
--- /dev/null
+++ b/http/cs/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentace}}
diff --git a/http/cs/request.texy b/http/cs/request.texy
index 5dc90de308..1827f489e0 100644
--- a/http/cs/request.texy
+++ b/http/cs/request.texy
@@ -184,6 +184,30 @@ $body = $httpRequest->getRawBody();
```
+getOrigin(): ?UrlImmutable .[method]
+------------------------------------
+Vrací origin, ze kterého požadavek přišel. Origin se skládá z protokolu, hostname a portu - například `https://example.com:8080`. Vrací `null`, pokud hlavička origin není přítomna nebo je nastavena na `'null'`.
+
+```php
+$origin = $httpRequest->getOrigin();
+echo $origin; // https://example.com:8080
+echo $origin?->getHost(); // example.com
+```
+
+Prohlížeč posílá hlavičku `Origin` v následujících případech:
+- Požadavky mezi doménami (AJAX volání na jinou doménu)
+- POST, PUT, DELETE a další modifikující požadavky
+- Požadavky provedené pomocí Fetch API
+
+Prohlížeč NEPOSÍLÁ hlavičku `Origin` při:
+- Běžných GET požadavcích na stejnou doménu (navigace v rámci téže domény)
+- Přímé navigaci zadáním URL do adresního řádku
+- Požadavcích z jiných klientů než prohlížeče (pokud není ručně přidána)
+
+.[note]
+Na rozdíl od hlavičky `Referer` obsahuje `Origin` pouze schéma, host a port - nikoli celou cestu URL. To ji činí vhodnější pro bezpečnostní kontroly při zachování soukromí uživatele. Hlavička `Origin` se primárně používá pro validaci [CORS |nette:glossary#Cross-Origin Resource Sharing (CORS)] (Cross-Origin Resource Sharing).
+
+
detectLanguage(array $langs): ?string .[method]
-----------------------------------------------
Detekuje jazyk. Jako parametr `$lang` předáme pole s jazyky, které aplikace podporuje, a ona vrátí ten, který by viděl návštěvníkův prohlížeč nejraději. Nejsou to žádná kouzla, jen se využívá hlavičky `Accept-Language`. Pokud nedojde k žádné shodě, vrací `null`.
@@ -389,6 +413,11 @@ getTemporaryFile(): string .[method]
Vrací cestu k dočasné lokaci uploadovaného souboru. V případě, že upload nebyl úspěšný, vrací `''`.
+__toString(): string .[method]
+------------------------------
+Vrací cestu k dočasnému umístění nahraného souboru. To umožňuje objekt `FileUpload` použít přímo jako řetězec.
+
+
isImage(): bool .[method]
-------------------------
Vrací `true`, pokud nahraný soubor je obrázek ve formátu JPEG, PNG, GIF, WebP nebo AVIF. Detekce probíhá na základě jeho signatury a neověřuje se integrita celého souboru. Zda není obrázek poškozený lze zjistit například pokusem o jeho [načtení |#toImage].
diff --git a/http/cs/response.texy b/http/cs/response.texy
index baea11f900..4732bc7a76 100644
--- a/http/cs/response.texy
+++ b/http/cs/response.texy
@@ -34,9 +34,9 @@ isSent(): bool .[method]
Vrací, zda už došlo k odeslání hlaviček ze serveru do prohlížeče, a tedy již není možné odesílat hlavičky či měnit stavový kód.
-setHeader(string $name, string $value) .[method]
-------------------------------------------------
-Odešle HTTP hlavičku a **přepíše** dříve odeslanou hlavičkou stejného jména.
+setHeader(string $name, ?string $value) .[method]
+-------------------------------------------------
+Odešle HTTP hlavičku a **přepíše** dříve odeslanou hlavičkou stejného jména. Pokud je `$value` `null`, bude záhlaví odstraněno.
```php
$httpResponse->setHeader('Pragma', 'no-cache');
@@ -115,8 +115,8 @@ $httpResponse->sendAsFile('faktura.pdf');
```
-setCookie(string $name, string $value, $time, ?string $path=null, ?string $domain=null, ?bool $secure=null, ?bool $httpOnly=null, ?string $sameSite=null) .[method]
--------------------------------------------------------------------------------------------------------------------------------------------------------------------
+setCookie(string $name, string $value, $time, ?string $path=null, ?string $domain=null, ?bool $secure=null, ?bool $httpOnly=null, ?string $sameSite='Lax') .[method]
+--------------------------------------------------------------------------------------------------------------------------------------------------------------------
Odešle cookie. Výchozí hodnoty parametrů:
| `$path` | `'/'` | cookie má dosah na všechny cesty v (sub)doméně *(konfigurovatelné)*
diff --git a/http/cs/sessions.texy b/http/cs/sessions.texy
index f4ef752aec..de10e7715f 100644
--- a/http/cs/sessions.texy
+++ b/http/cs/sessions.texy
@@ -23,7 +23,7 @@ Správu session má na starosti objekt [api:Nette\Http\Session], ke kterému se
Start session
=============
-Nette ve výchozím nastavení automaticky zahájí session automaticky ve chvíli, když z ní začneme číst nebo do ní zapisovat data. Ručně se session zahájí pomocí `$session->start()`.
+Nette ve výchozím nastavení automaticky zahájí session ve chvíli, když z ní začneme číst nebo do ní zapisovat data. Ručně se session zahájí pomocí `$session->start()`.
PHP odešle při spuštění session HTTP hlavičky ovlivňující kešování, viz [php:session_cache_limiter], a případně i cookie se session ID. Proto je nutné vždy session nastartovat ještě před odesláním jakéhokoliv výstupu do prohlížeče, jinak dojde k vyhození výjimky. Pokud tedy víte, že v průběhu vykreslování stránky se bude používat session, nastartujte ji ručně předtím, třeba v presenteru.
diff --git a/http/cs/urls.texy b/http/cs/urls.texy
index 9e722a9d7c..e40a157e18 100644
--- a/http/cs/urls.texy
+++ b/http/cs/urls.texy
@@ -82,6 +82,7 @@ Můžeme pracovat i s jednotlivými query parametry pomocí:
|---------------------------------------------------
| `setQuery(string\|array $query)` | `getQueryParameters(): array`
| `setQueryParameter(string $name, $val)` | `getQueryParameter(string $name)`
+| `appendQuery(string|array $query)` |
getDomain(int $level = 2): string .[method]
@@ -107,6 +108,11 @@ $url->isEqual('https://nette.org');
```
+canonicalize() .[method]
+------------------------
+Převede URL do kanonického tvaru. To zahrnuje například seřazení parametrů v query stringu podle abecedy, převod hostname na malá písmena a odstranění nadbytečných znaků.
+
+
Url::isAbsolute(string $url): bool .[method]{data-version:3.3.2}
----------------------------------------------------------------
Ověřuje, zda je URL absolutní. URL je považována za absolutní, pokud začíná schématem (např. http, https, ftp) následovaným dvojtečkou.
diff --git a/http/de/@meta.texy b/http/de/@meta.texy
new file mode 100644
index 0000000000..b3b806b2ca
--- /dev/null
+++ b/http/de/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentation}}
diff --git a/http/el/@meta.texy b/http/el/@meta.texy
new file mode 100644
index 0000000000..88e29852c7
--- /dev/null
+++ b/http/el/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Τεκμηρίωση}}
diff --git a/http/en/@meta.texy b/http/en/@meta.texy
new file mode 100644
index 0000000000..42471908b0
--- /dev/null
+++ b/http/en/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentation}}
diff --git a/http/en/request.texy b/http/en/request.texy
index ae45438508..47e0232f54 100644
--- a/http/en/request.texy
+++ b/http/en/request.texy
@@ -184,6 +184,30 @@ $body = $httpRequest->getRawBody();
```
+getOrigin(): ?UrlImmutable .[method]
+------------------------------------
+Returns the origin from which the request came. An origin consists of the scheme (protocol), hostname, and port - for example, `https://example.com:8080`. Returns `null` if the origin header is not present or is set to `'null'`.
+
+```php
+$origin = $httpRequest->getOrigin();
+echo $origin; // https://example.com:8080
+echo $origin?->getHost(); // example.com
+```
+
+The browser sends the `Origin` header in the following cases:
+- Cross-origin requests (AJAX calls to a different domain)
+- POST, PUT, DELETE, and other modifying requests
+- Requests made using the Fetch API
+
+The browser does NOT send the `Origin` header for:
+- Regular GET requests to the same domain (same-origin navigation)
+- Direct navigation by typing a URL into the address bar
+- Requests from non-browser clients
+
+.[note]
+Unlike the `Referer` header, `Origin` contains only the scheme, host, and port - not the full URL path. This makes it more suitable for security checks while preserving user privacy. The `Origin` header is primarily used for [CORS |nette:glossary#Cross-Origin Resource Sharing (CORS)] (Cross-Origin Resource Sharing) validation.
+
+
detectLanguage(array $langs): ?string .[method]
-----------------------------------------------
Detects the language. Pass an array of languages supported by the application as the `$langs` parameter, and it will return the one preferred by the visitor's browser. It's not magic; it just uses the `Accept-Language` header. If no match is found, it returns `null`.
@@ -389,6 +413,11 @@ getTemporaryFile(): string .[method]
Returns the path to the temporary location of the uploaded file. If the upload was not successful, it returns `''`.
+__toString(): string .[method]
+------------------------------
+Returns the path to the temporary location of the uploaded file. This allows the `FileUpload` object to be used directly as a string.
+
+
isImage(): bool .[method]
-------------------------
Returns `true` if the uploaded file is a JPEG, PNG, GIF, WebP, or AVIF image. Detection is based on its signature and does not verify the integrity of the entire file. Whether an image is corrupted can be determined, for example, by trying to [load it |#toImage].
diff --git a/http/en/response.texy b/http/en/response.texy
index 7654f039e9..7dbd4dca00 100644
--- a/http/en/response.texy
+++ b/http/en/response.texy
@@ -34,9 +34,9 @@ isSent(): bool .[method]
Returns whether headers have already been sent from the server to the browser, meaning it is no longer possible to send headers or change the status code.
-setHeader(string $name, string $value) .[method]
-------------------------------------------------
-Sends an HTTP header and **overwrites** a previously sent header of the same name.
+setHeader(string $name, ?string $value) .[method]
+-------------------------------------------------
+Sends an HTTP header and **overwrites** a previously sent header of the same name. If `$value` is `null`, the header will be removed.
```php
$httpResponse->setHeader('Pragma', 'no-cache');
@@ -115,8 +115,8 @@ $httpResponse->sendAsFile('invoice.pdf');
```
-setCookie(string $name, string $value, $time, ?string $path=null, ?string $domain=null, ?bool $secure=null, ?bool $httpOnly=null, ?string $sameSite=null) .[method]
--------------------------------------------------------------------------------------------------------------------------------------------------------------------
+setCookie(string $name, string $value, $time, ?string $path=null, ?string $domain=null, ?bool $secure=null, ?bool $httpOnly=null, ?string $sameSite='Lax') .[method]
+--------------------------------------------------------------------------------------------------------------------------------------------------------------------
Sends a cookie. Default parameter values:
| `$path` | `'/'` | cookie is available for all paths within the (sub)domain *(configurable)*
diff --git a/http/en/urls.texy b/http/en/urls.texy
index 84a947c12f..608fa0064f 100644
--- a/http/en/urls.texy
+++ b/http/en/urls.texy
@@ -82,6 +82,7 @@ We can also work with individual query parameters using:
|---------------------------------------------------
| `setQuery(string\|array $query)` | `getQueryParameters(): array`
| `setQueryParameter(string $name, $val)` | `getQueryParameter(string $name)`
+| `appendQuery(string|array $query)` |
getDomain(int $level = 2): string .[method]
@@ -107,6 +108,11 @@ $url->isEqual('https://nette.org');
```
+canonicalize() .[method]
+------------------------
+Converts the URL to canonical form. This includes, for example, sorting the parameters in the query string alphabetically, converting the hostname to lowercase, and removing redundant characters.
+
+
Url::isAbsolute(string $url): bool .[method]{data-version:3.3.2}
----------------------------------------------------------------
Checks if a URL is absolute. A URL is considered absolute if it begins with a scheme (e.g., http, https, ftp) followed by a colon.
diff --git a/http/es/@meta.texy b/http/es/@meta.texy
new file mode 100644
index 0000000000..1670b124ad
--- /dev/null
+++ b/http/es/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Documentación}}
diff --git a/http/fr/@meta.texy b/http/fr/@meta.texy
new file mode 100644
index 0000000000..72ae4b8db8
--- /dev/null
+++ b/http/fr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentation Nette}}
diff --git a/http/hu/@meta.texy b/http/hu/@meta.texy
new file mode 100644
index 0000000000..c172d1cda5
--- /dev/null
+++ b/http/hu/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette dokumentáció}}
diff --git a/http/it/@meta.texy b/http/it/@meta.texy
new file mode 100644
index 0000000000..4647d0c8a2
--- /dev/null
+++ b/http/it/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentazione Nette}}
diff --git a/http/ja/@meta.texy b/http/ja/@meta.texy
new file mode 100644
index 0000000000..d3c41dc3d7
--- /dev/null
+++ b/http/ja/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette ドキュメンテーション}}
diff --git a/http/pl/@meta.texy b/http/pl/@meta.texy
new file mode 100644
index 0000000000..61ac92d1af
--- /dev/null
+++ b/http/pl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Dokumentacja Nette}}
diff --git a/http/pt/@meta.texy b/http/pt/@meta.texy
new file mode 100644
index 0000000000..41a853b6aa
--- /dev/null
+++ b/http/pt/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentação Nette}}
diff --git a/http/ro/@meta.texy b/http/ro/@meta.texy
new file mode 100644
index 0000000000..9c744b37d6
--- /dev/null
+++ b/http/ro/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Documentație Nette}}
diff --git a/http/ru/@meta.texy b/http/ru/@meta.texy
new file mode 100644
index 0000000000..7f329adfce
--- /dev/null
+++ b/http/ru/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация Nette}}
diff --git a/http/sl/@meta.texy b/http/sl/@meta.texy
new file mode 100644
index 0000000000..724324bee5
--- /dev/null
+++ b/http/sl/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokumentacija}}
diff --git a/http/tr/@meta.texy b/http/tr/@meta.texy
new file mode 100644
index 0000000000..8dfe82f311
--- /dev/null
+++ b/http/tr/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Nette Dokümantasyonu}}
diff --git a/http/uk/@meta.texy b/http/uk/@meta.texy
new file mode 100644
index 0000000000..96e2d9752a
--- /dev/null
+++ b/http/uk/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документація Nette}}
diff --git a/latte/bg/@menu.texy b/latte/bg/@menu.texy
index c0fceec790..c6324fc01c 100644
--- a/latte/bg/@menu.texy
+++ b/latte/bg/@menu.texy
@@ -5,8 +5,8 @@
Инструменти
- [fiddle |https://fiddle.nette.org]
-- [php2Latte |https://php2latte.nette.org]
-- [twig2Latte|https://twig2latte.nette.org]
+- [php2Latte |https://fiddle.nette.org/php2latte/]
+- [twig2Latte|https://fiddle.nette.org/twig2latte/]
diff --git a/latte/bg/@meta.texy b/latte/bg/@meta.texy
new file mode 100644
index 0000000000..4297aeff19
--- /dev/null
+++ b/latte/bg/@meta.texy
@@ -0,0 +1 @@
+{{sitename: Документация на Latte}}
diff --git a/latte/bg/cookbook/@home.texy b/latte/bg/cookbook/@home.texy
index aef61d9504..019aa6cd32 100644
--- a/latte/bg/cookbook/@home.texy
+++ b/latte/bg/cookbook/@home.texy
@@ -11,5 +11,3 @@
- [Миграция от PHP |migration-from-php]
- [Миграция от Twig |migration-from-twig]
- [Използване на Latte със Slim 4 |slim-framework]
-
-{{leftbar: /@left-menu}}
diff --git a/latte/bg/cookbook/@meta.texy b/latte/bg/cookbook/@meta.texy
new file mode 100644
index 0000000000..64e87d1168
--- /dev/null
+++ b/latte/bg/cookbook/@meta.texy
@@ -0,0 +1,2 @@
+{{sitename: Документация на Latte}}
+{{leftbar: /@left-menu}}
diff --git a/latte/bg/cookbook/grouping.texy b/latte/bg/cookbook/grouping.texy
index 94c13cf7c5..fe6ac48fe5 100644
--- a/latte/bg/cookbook/grouping.texy
+++ b/latte/bg/cookbook/grouping.texy
@@ -249,6 +249,3 @@
{/foreach}
```
-
-
-{{leftbar: /@left-menu}}
diff --git a/latte/bg/cookbook/how-to-write-sql-queries-in-latte.texy b/latte/bg/cookbook/how-to-write-sql-queries-in-latte.texy
index 07d0e7a37a..b6a002275e 100644
--- a/latte/bg/cookbook/how-to-write-sql-queries-in-latte.texy
+++ b/latte/bg/cookbook/how-to-write-sql-queries-in-latte.texy
@@ -38,5 +38,3 @@ $result = $db->query($sql);
```
*Посоченият пример изисква Latte v3.0.5 или по-нова версия.*
-
-{{leftbar: /@left-menu}}
diff --git a/latte/bg/cookbook/migration-from-php.texy b/latte/bg/cookbook/migration-from-php.texy
index 4b5e21c1e0..73be04cf53 100644
--- a/latte/bg/cookbook/migration-from-php.texy
+++ b/latte/bg/cookbook/migration-from-php.texy
@@ -2,7 +2,7 @@
*************************
.[perex]
-Преобразувате стар проект, написан на чист PHP, към Latte? Имаме за вас инструмент, който ще ви улесни миграцията. [Изпробвайте го онлайн |https://php2latte.nette.org].
+Преобразувате стар проект, написан на чист PHP, към Latte? Имаме за вас инструмент, който ще ви улесни миграцията. [Изпробвайте го онлайн |https://fiddle.nette.org/php2latte/].
Можете да изтеглите инструмента от [GitHub|https://github.com/nette/latte-tools] или да го инсталирате с помощта на Composer:
@@ -68,5 +68,3 @@ foreach ($result as $cur_group) {
```
-
-{{leftbar: /@left-menu}}
diff --git a/latte/bg/cookbook/migration-from-twig.texy b/latte/bg/cookbook/migration-from-twig.texy
index 406bb4de13..04e356b464 100644
--- a/latte/bg/cookbook/migration-from-twig.texy
+++ b/latte/bg/cookbook/migration-from-twig.texy
@@ -2,7 +2,7 @@
**************************
.[perex]
-Преобразувате проект, написан на Twig, към по-модерния Latte? Имаме за вас инструмент, който ще ви улесни миграцията. [Изпробвайте го онлайн |https://twig2latte.nette.org].
+Преобразувате проект, написан на Twig, към по-модерния Latte? Имаме за вас инструмент, който ще ви улесни миграцията. [Изпробвайте го онлайн |https://fiddle.nette.org/twig2latte/].
Можете да изтеглите инструмента от [GitHub|https://github.com/nette/latte-tools] или да го инсталирате с помощта на Composer:
@@ -77,5 +77,3 @@ php twig-to-latte.php input.twig.html [output.latte]