<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
</head>
<body>
@yield('content')
@yield('comment')
@yield('news')
</body>
</html>
@extends('layouts.app')
@section('content')
{{ $content = 'Контент' }} <br>
@endsection
@section('comment')
{{ $comment = 'Коммент' }} <br>
@endsection
@section('news')
{{ $news = 'Новости' }} <br>
@endsection
@extends('news.index')
@section('content')
{{ $news = 'Вложенные новости' }} <br><br>
@endsection
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Document</title>
</head>
<body>
@yield('content')
@yield('comment')
@yield('news')
</body>
</html>
@extends('layouts.app')
@section('content')
{{ $content = 'Контент' }} <br>
@endsection
@section('comment')
{{ $comment = 'Коммент' }} <br>
@endsection
@section('news')
{{ $news = 'Новости' }} <br>
@endsection
@extends('news.index')
@section('content')
{{ $news = 'Вложенные новости' }} <br><br>
@endsection
if (isset($_POST["username"]) && !empty($_POST["username"])) {
echo "Yes, usernameis set";
}else{
echo "N0, username is not set";
}
$post = new Post($request->all());
public class Enter {
public static void main(String... args){
new ColorLayout();
}
}
import java.awt.*;
import java.awt.Dimension;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JPanel;
@SuppressWarnings("serial")
public class ColorLayout extends JFrame{
public ColorLayout() {
this.add(new ColorPanel());
this.setLocationRelativeTo(null);
this.setDefaultCloseOperation(EXIT_ON_CLOSE);
this.setSize(new Dimension(200,200));
this.setVisible(true);
}
public class ColorPanel extends JPanel{
private JButton button;
private JPanel buttonpanel;
public ColorPanel() {
buttonpanel = new JPanel();
buttonpanel.setBackground(Color.decode("#eeeeee"));
button = new JButton("Жми, чтобы узнать цвет");
button.addActionListener(new ActionListener() {
@Override
public void actionPerformed(ActionEvent arg0) {
System.out.println(buttonpanel.getBackground());
}
});
buttonpanel.add(button);
this.add(buttonpanel);
}
}
}