Questions tagged [nette]

Nette Framework is an open source tool for PHP web development. Nette focuses on security and performance and it's one of the safest PHP frameworks.

Nette Framework is an MVC framework developed by David Grudl. It is designed to be as easy as possible to use and it is one of the safest frameworks.

Latte is used as a primary templating engine which has features such as macros, filters, context-aware output escaping, localization support or custom blocks.

Nette offers an easy to use service container, allowing to register singleton or factory created services. The service container also supports Dependency Injection with automatic (can be disabled) injection of services into constructors of other services or controllers.

Current Nette version: 2.4

Resources

142 questions
1
vote
1 answer

Nette phar boot file

I'm trying to create a single-file version of PHP framework Nette 2.4. I create a phar file using this code: buildFromDirectory(__DIR__ . '/../vendor/nette'); $phar->setStub("
Mr. Human
  • 23
  • 1
  • 6
1
vote
2 answers

Latte - call function in TPL (ideally with parameter) instead of variable

I decided to rewrite an older website that I made years ago and use templating system. I decided to use Latte, as its generating PHP files, which makes it really fast compared to systems that parse tpl every time. But I was not able to figure out,…
MiChAeLoKGB
  • 796
  • 14
  • 38
1
vote
2 answers

Nette: Models vs vendor lib

I have few models, which I've been implementing for a while in every sandbox project and it got me thinking. What is the difference between few models with constant implementation Vs. my own lib, which would in theory contain same files. Question…
Vladimir
  • 388
  • 1
  • 13
1
vote
0 answers

Doctrine 2 - Many-To-One, Unidirectional -- not configured to cascade persist operations

I have little bit problem with doctrine 2 (Many-To-One, Unidirectional assoc.). If I save only log without file, then log will be save, but if I add file to log, i got this error messages (pictures at the bottom of question). I have same problem…
Jan Sršeň
  • 1,045
  • 3
  • 23
  • 46
1
vote
1 answer

Nette component with AJAX form

i making nette component like DataGrid. I have one basecomponent BaseGrid. In this component i calling another component Filter public function createComponentFilter() { return new Multiplier(function ($columnName) { …
1
vote
1 answer

how to open presenter in browser address?

I have Homepage presenter i want to view what inside it in homepage. how can i open it in webaddress ? i already try to open it with this http://localhost/sandbox/www/homepage/action it wont open What the different between method action and…
navotera
  • 321
  • 1
  • 15
1
vote
1 answer

Regex Replace Nette and Latte in ApiGen

I'm using the Bootstrap Template for ApiGen and I want to replace the default source code views with Highlight.js. This requires me to remove the existing spans produced by ApiGen using the Nette replaceRE filter. The original code looks like…
secondman
  • 3,233
  • 6
  • 43
  • 66
1
vote
0 answers

Doctrine OneToMany collection clear() and orphanRemoval

My Article Entity has collection $internalAuthors /** * @ORM\OneToMany(targetEntity = "ArticleModule\Model\Entities\ArticleInternalAuthor", mappedBy = "article", cascade = {"persist"}) */ protected $internalAuthors; If I want to clear this…
1
vote
1 answer

mPDF footer showing only on last page

I have a problem with mPDF footer generating. I am using mPDF with nette framework {include #content}
1
vote
2 answers

Update database by script or session?

I have function in php, where I update a database. I have url something like http://localhost/products/feed/update How can I update database every 15 minutes? It is better script or session or how to do this?
Juraj Lúdik
  • 83
  • 1
  • 7
1
vote
2 answers

Invalid link: Cannot load presenter 'Post', class 'App\Presenters\PostPresenter' was not found

I am new to Nette framework, I have done everything correctly but it shows the following warning My Files Look like this Any Help will be greatly appreciated. Thanks
Muhammad
  • 6,725
  • 5
  • 47
  • 54
1
vote
1 answer

Installing PHP Project Dependencies with Composer

I am trying to install Nette2.3.1 using Composer (on XAMPP). In c:\x\php folder I run this command: composer create-project nette/sandbox myprojectname When I do this, getting following error: [Seld\JsonLint\ParsingException] "c:\x\php\php.exe"…
Pura
  • 141
  • 1
  • 6
1
vote
1 answer

Change google chart type using ajax

I have this js: